@otalan/cli 1.0.9 → 1.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +13 -0
- package/README.md +46 -13
- package/dist/bin.js +34 -33
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,19 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to `@otalan/cli` will be documented in this file.
|
|
4
4
|
|
|
5
|
+
## 1.1.0 - 2026-05-07
|
|
6
|
+
|
|
7
|
+
### Added
|
|
8
|
+
|
|
9
|
+
- List active project apps during `otalan init` and validate `--app-id` against the logged-in project.
|
|
10
|
+
|
|
11
|
+
### Changed
|
|
12
|
+
|
|
13
|
+
- Let `otalan login` reuse the saved API URL and keep the saved CI key from a masked prompt.
|
|
14
|
+
- Export Expo bundles into a project-local `.otalan/expo-export-*` folder so Expo accepts the output path.
|
|
15
|
+
- Fall back to the resolved native version when Expo runtimeVersion is not configured or present in export metadata.
|
|
16
|
+
- Clarify Capacitor and Expo / React Native bundling behavior in CLI help and README.
|
|
17
|
+
|
|
5
18
|
## 1.0.9 - 2026-05-06
|
|
6
19
|
|
|
7
20
|
### Added
|
package/README.md
CHANGED
|
@@ -50,7 +50,7 @@ otalan login --api-key otalan_ci_xxx
|
|
|
50
50
|
2. Link the current repo to your active Otalan app:
|
|
51
51
|
|
|
52
52
|
```bash
|
|
53
|
-
otalan init
|
|
53
|
+
otalan init
|
|
54
54
|
```
|
|
55
55
|
|
|
56
56
|
3. Build your web assets with your app's normal build command.
|
|
@@ -67,7 +67,7 @@ otalan bundle --target capacitor --platform ios --bundle-id 1.0.5
|
|
|
67
67
|
otalan publish --channel production
|
|
68
68
|
```
|
|
69
69
|
|
|
70
|
-
`otalan bundle --target capacitor` packages
|
|
70
|
+
`otalan bundle --target capacitor` packages existing built web assets. By default it reads `dist/` first, then `www/`; pass `--input-dir <path>` if your build outputs somewhere else. Your app build must run first.
|
|
71
71
|
`otalan publish` waits for server-side validation to finish before it returns.
|
|
72
72
|
|
|
73
73
|
### Expo / React Native
|
|
@@ -81,7 +81,7 @@ otalan login --api-key otalan_ci_xxx
|
|
|
81
81
|
2. Link the current repo to your active Otalan app:
|
|
82
82
|
|
|
83
83
|
```bash
|
|
84
|
-
otalan init
|
|
84
|
+
otalan init
|
|
85
85
|
```
|
|
86
86
|
|
|
87
87
|
3. Bundle the OTA payload:
|
|
@@ -96,7 +96,7 @@ otalan bundle --target expo --platform ios --bundle-id 1.0.5
|
|
|
96
96
|
otalan publish --channel production
|
|
97
97
|
```
|
|
98
98
|
|
|
99
|
-
`otalan bundle --target expo` runs `bunx expo export
|
|
99
|
+
`otalan bundle --target expo` runs `bunx expo export` itself, exports into a temporary project-local `.otalan/expo-export-*` folder, packages the exported JS bundle and assets, and stores the resolved Expo config in the Otalan manifest for publish. You do not need to create a `dist/` or `www/` folder before running it.
|
|
100
100
|
`otalan publish` waits for server-side validation to finish before it returns.
|
|
101
101
|
|
|
102
102
|
## CI/CD Usage
|
|
@@ -124,7 +124,7 @@ otalan bundle --target capacitor --platform ios --bundle-from-package
|
|
|
124
124
|
otalan publish --channel production
|
|
125
125
|
```
|
|
126
126
|
|
|
127
|
-
Use your normal app build command before `otalan bundle`. The CLI then packages the built web output from `dist/` or `www
|
|
127
|
+
Use your normal app build command before `otalan bundle`. The CLI then packages the built web output from `dist/` or `www/` by default; pass `--input-dir <path>` if your Capacitor web output uses another folder.
|
|
128
128
|
|
|
129
129
|
### CI/CD Example: Expo / React Native
|
|
130
130
|
|
|
@@ -137,7 +137,7 @@ otalan bundle --target expo --platform ios --bundle-from-package
|
|
|
137
137
|
otalan publish --channel production
|
|
138
138
|
```
|
|
139
139
|
|
|
140
|
-
This runs `bunx expo export` through the CLI, packages the exported OTA assets, and publishes the resulting bundle through Otalan's validation pipeline.
|
|
140
|
+
This runs `bunx expo export` through the CLI, using a temporary project-local `.otalan/expo-export-*` folder, packages the exported OTA assets, and publishes the resulting bundle through Otalan's validation pipeline. Do not add a separate web build step just to create `dist/` or `www/` for Expo / React Native.
|
|
141
141
|
|
|
142
142
|
### GitHub Actions Example
|
|
143
143
|
|
|
@@ -258,7 +258,9 @@ xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
|
|
|
258
258
|
|
|
259
259
|
### `otalan login`
|
|
260
260
|
|
|
261
|
-
Saves the CI key and API base URL locally.
|
|
261
|
+
Saves the project CI key and API base URL locally.
|
|
262
|
+
|
|
263
|
+
If auth is already saved, `otalan login` shows the current API URL as the prompt default and shows the current CI key in masked form. Press Enter to keep either value.
|
|
262
264
|
|
|
263
265
|
```bash
|
|
264
266
|
otalan login --api-key otalan_ci_xxx --api-url https://api.otalan.com
|
|
@@ -282,11 +284,15 @@ otalan doctor --api-key "$OTALAN_API_KEY" --api-url "${OTALAN_API_URL:-https://a
|
|
|
282
284
|
|
|
283
285
|
Creates `otalan.config.json` in the current project.
|
|
284
286
|
|
|
285
|
-
`
|
|
287
|
+
`otalan init` lists the active apps in the project resolved from the logged-in CI key and lets you select one. `appId` is scoped to that project, not globally unique across all projects. Archived apps are not listed and are treated as unavailable for CI publish, rollback, status, and bundle listing commands.
|
|
288
|
+
|
|
289
|
+
Run `otalan init` once per app repo or working folder. If you switch to another checkout, folder, or app project, run `otalan init` there too so that folder has its own `otalan.config.json`.
|
|
286
290
|
|
|
287
|
-
If you
|
|
291
|
+
If you pass `--app-id`, the CLI validates that the app exists in the logged-in project before writing `otalan.config.json`. The CLI also stores `organizationSlug` and `projectSlug` from the CI key as a safety check.
|
|
288
292
|
|
|
289
293
|
```bash
|
|
294
|
+
otalan init
|
|
295
|
+
# Non-interactive CI usage:
|
|
290
296
|
otalan init \
|
|
291
297
|
--app-id com.example.app
|
|
292
298
|
```
|
|
@@ -301,6 +307,8 @@ Capacitor:
|
|
|
301
307
|
|
|
302
308
|
```bash
|
|
303
309
|
otalan bundle --target capacitor --platform ios
|
|
310
|
+
# Custom Capacitor web output folder:
|
|
311
|
+
otalan bundle --target capacitor --platform ios --input-dir build
|
|
304
312
|
```
|
|
305
313
|
|
|
306
314
|
Expo / React Native:
|
|
@@ -311,9 +319,11 @@ otalan bundle --target expo --platform ios
|
|
|
311
319
|
|
|
312
320
|
Current behavior:
|
|
313
321
|
|
|
314
|
-
-
|
|
315
|
-
- Capacitor
|
|
316
|
-
-
|
|
322
|
+
- Capacitor packages prebuilt web assets; it does not run your app build command
|
|
323
|
+
- without `--input-dir`, Capacitor checks `dist/` first and then `www/`
|
|
324
|
+
- pass `--input-dir <path>` to package a different Capacitor web output folder
|
|
325
|
+
- Expo / React Native runs `bunx expo export --platform <platform>` into a temporary project-local `.otalan/expo-export-*` folder
|
|
326
|
+
- Expo / React Native does not require a prebuilt `dist/` or `www/` folder
|
|
317
327
|
- Expo stores the resolved Expo app config in `.otalan/bundle/manifest.json` so publish can forward it for `extra.expoClient`
|
|
318
328
|
- both outputs produce a ZIP plus `manifest.json`
|
|
319
329
|
- `--platform` is required so the CLI exports the selected platform and resolves the correct native/runtime version
|
|
@@ -324,9 +334,32 @@ Native version defaults:
|
|
|
324
334
|
- Capacitor iOS reads `CFBundleShortVersionString` from `Info.plist` and resolves `$(MARKETING_VERSION)` from the Xcode project when needed
|
|
325
335
|
- Capacitor Android reads `versionName` from `android/app/build.gradle` or `build.gradle.kts`
|
|
326
336
|
- Expo reads the selected platform version from Expo config and falls back to the top-level Expo `version`
|
|
327
|
-
- Expo runtimeVersion reads `--runtime-version`, Expo export metadata, or Expo config runtimeVersion policies/strings
|
|
337
|
+
- Expo runtimeVersion reads `--runtime-version`, Expo export metadata, or Expo config runtimeVersion policies/strings; if none are present, the CLI falls back to the resolved native version
|
|
328
338
|
- `--native-version` overrides auto-detection
|
|
329
339
|
|
|
340
|
+
For Expo projects, the recommended app config is:
|
|
341
|
+
|
|
342
|
+
```json
|
|
343
|
+
{
|
|
344
|
+
"expo": {
|
|
345
|
+
"version": "1.0.0",
|
|
346
|
+
"runtimeVersion": {
|
|
347
|
+
"policy": "appVersion"
|
|
348
|
+
}
|
|
349
|
+
}
|
|
350
|
+
}
|
|
351
|
+
```
|
|
352
|
+
|
|
353
|
+
Use a string value instead if you manage runtime compatibility manually:
|
|
354
|
+
|
|
355
|
+
```json
|
|
356
|
+
{
|
|
357
|
+
"expo": {
|
|
358
|
+
"runtimeVersion": "1.0.0"
|
|
359
|
+
}
|
|
360
|
+
}
|
|
361
|
+
```
|
|
362
|
+
|
|
330
363
|
Choose the bundle ID you want to release:
|
|
331
364
|
|
|
332
365
|
```bash
|