Compare commits

...
Author SHA1 Message Date
Quinlan Jung 14d491a558 [eas-cli] unify channel graphql query types 2023-07-24 15:54:43 -07:00
Expo CI 51d0555baa update CHANGELOG.md 2023-07-24 17:24:12 +00:00
Szymon Dziedzic 2137176a65 v3.17.0 2023-07-24 19:16:40 +02:00
Szymon Dziedzic 3fda52c8d7 [eas-cli] handle server side defined error for situation when intel-medium is not available and remove intel-medium for eas.schema.json (#1947)
* [eas-cli] handle server side defined error when `intel-medium` resource class is not available

* don't suggest using `intel-medium` in `eas.schema.json`

* update CHANGELOG.md

* update CHANGELOG.md
2023-07-24 19:08:10 +02:00
Quinlan Jung b252b5b582 [eas-cli] utils: amend rollouts definition (#1945)
* [eas-cli] utils: amend rollouts definition

* update CHANGELOG.md
2023-07-24 09:10:07 -07:00
Szymon Dziedzic 2befe410cf [eas-cli] allow for rollout option when configuring submission (#1938)
* [eas-cli] allow for `rollout` option when configuring submission

* update CHANGELOG.md

* add entry to `eas.schema.json`

* improve eas.schema.json

* make rollout default to 1 if not set

* Revert "make rollout default to 1 if not set"

This reverts commit 2ab689b02c.

* generate schema against staging

* update fragment
2023-07-24 14:05:10 +02:00
Quinlan Jung 1463e0de74 [eas-cli] branch mapping utility functions (#1944)
* [eas-cli] branch mapping primitives

* refactor

* extra test

* update CHANGELOG.md
2023-07-20 12:45:40 -07:00
Piotr Szeremeta e963558ef6 [ENG-8956][eas-build] Improve EAS CLI tsconfig.json for local development (#1933)
Changed noUnusedLocals and noUnusedParameters to false for easier local development and experimenting.
These checks do not run during local development. Instead, `yarn build` catches these cases on github.
2023-07-20 16:35:52 +02:00
Quinlan Jung fe57c055b6 [eas-cli] bump urql graphql client (#1936)
* [eas-cli] bump urql graphql client

* update CHANGELOG.md

* fix test
2023-07-19 10:34:04 -07:00
Expo CI 045840111e update CHANGELOG.md 2023-07-18 16:13:46 +00:00
Szymon Dziedzic 9a6068c1f2 v3.16.0 2023-07-18 18:04:52 +02:00
Szymon Dziedzic d06a77bd6d [eas-cli] fix incorrect handling of valid inProgress release status (#1934)
* [eas-cli] fix incorrect handling of valid `inProgress` release status

* update CHANGELOG.md

* add another test
2023-07-18 15:47:45 +02:00
Szymon Dziedzic 7bcf83d141 Revert "add another test"
This reverts commit cd9323e115.
2023-07-18 15:34:09 +02:00
Szymon Dziedzic cd9323e115 add another test 2023-07-18 15:33:15 +02:00
Firas Regaieg 34145c38ca [Build] Print friendly error msg in case account doesn't have required permission (#1867)
* Print friendly error msg (reviewed)

Comment: This is useful when credentials fail, if user doesn't have permissions.

* Print friendly error msg - 2nd review

* Print friendly error msg - 2nd review (reviewed)

* Replace changelog event under main section
2023-07-18 15:28:33 +02:00
Piotr SzeremetaandSzymon Dziedzic 57dd372957 [ENG-9283][eas-cli] Throw error when project tarball exceeds 1GB (#1928)
* [ENG-9283][eas-cli] Throw error when project tarball exceeds 1GB

* update CHANGELOG.md

* Update packages/eas-cli/src/build/build.ts

Co-authored-by: Szymon Dziedzic <[email protected]>

* Update packages/eas-cli/src/build/build.ts

Co-authored-by: Szymon Dziedzic <[email protected]>

* Update CHANGELOG.md

Co-authored-by: Szymon Dziedzic <[email protected]>

---------

Co-authored-by: Szymon Dziedzic <[email protected]>
2023-07-17 14:12:17 +02:00
Will Schurman 5232641217 [eas-cli] Use node server default port selection for SSO login server (#1930) 2023-07-13 09:29:51 -07:00
Cedric van Putten 3c3d3150c9 [eas-cli] Ignore the existing entitlements when ios is gitignored (#1906)
* [eas-cli] Ignore the existing entitlements when ios is gitignored

* chore: add changelog entry
2023-07-13 16:51:39 +02:00
Will Schurman fd322d4189 [eas-cli] Add styling to SSO auth redirect completion page (#1929) 2023-07-12 09:11:03 -07:00
Expo CI 77254f6be1 update CHANGELOG.md 2023-07-11 06:59:32 +00:00
44 changed files with 1500 additions and 390 deletions

No files matched your search

+4 -4
View File
@@ -29,7 +29,7 @@ jobs:
with:
node-version: 18
- run: yarn install --frozen-lockfile --check-files
- run: yarn build
- run: yarn build-ci
- name: Build tarballs
working-directory: ${{ github.workspace }}/packages/eas-cli
run: |
@@ -70,7 +70,7 @@ jobs:
with:
node-version: 18
- run: yarn install --frozen-lockfile --check-files
- run: yarn build
- run: yarn build-ci
- name: Build tarballs
working-directory: ${{ github.workspace }}/packages/eas-cli
run: |
@@ -99,7 +99,7 @@ jobs:
node-version: 18
- run: yarn install --frozen-lockfile --check-files
- run: sudo apt-get install nsis
- run: yarn build
- run: yarn build-ci
- run: |
yarn pretarball-ci
yarn oclif pack:win
@@ -142,7 +142,7 @@ jobs:
- name: Install dependencies
run: yarn install --frozen-lockfile --check-files
- name: Build
run: yarn build
run: yarn build-ci
- name: Publish packages to npm
run: yarn lerna publish from-package --yes --no-verify-access
env:
+37
View File
@@ -10,6 +10,43 @@ This is the log of notable changes to EAS CLI and related packages.
### 🐛 Bug fixes
### 🧹 Chores
## [3.17.0](https://github.com/expo/eas-cli/releases/tag/v3.17.0) - 2023-07-24
### 🎉 New features
- Add `rollout` option for configuring Android submissions. ([#1938](https://github.com/expo/eas-cli/pull/1938) by [@szdziedzic](https://github.com/szdziedzic))
### 🧹 Chores
- Added branch mapping utility functions. ([#1944](https://github.com/expo/eas-cli/pull/1944) by [@quinlanj](https://github.com/quinlanj))
- Amend branch mapping utility functions. ([#1945](https://github.com/expo/eas-cli/pull/1945) by [@quinlanj](https://github.com/quinlanj))
- Handle error thrown when `intel-medium` resource class is not available as server-side defined error. ([#1947](https://github.com/expo/eas-cli/pull/1947) by [@szdziedzic](https://github.com/szdziedzic))
- Remove `intel-medium` from `eas.schema.json`, so it's not suggested as a valid value by our VSCode plugin. ([#1947](https://github.com/expo/eas-cli/pull/1947) by [@szdziedzic](https://github.com/szdziedzic))
## [3.16.0](https://github.com/expo/eas-cli/releases/tag/v3.16.0) - 2023-07-18
### 🎉 New features
- Add styling to SSO auth redirect completion page. ([#1929](https://github.com/expo/eas-cli/pull/1929) by [@wschurman](https://github.com/wschurman))
- Ignore entitlements from native template when `/ios` is gitignored. ([#1906](https://github.com/expo/eas-cli/pull/1906) by [@byCedric](https://github.com/byCedric))
- Use node server default port selection for SSO login server. ([#1930](https://github.com/expo/eas-cli/pull/1930) by [@wschurman](https://github.com/wschurman))
### 🐛 Bug fixes
- Fix incorrect handling of valid `inProgress` Android submission release status. ([#1934](https://github.com/expo/eas-cli/pull/1934) by [@szdziedzic](https://github.com/szdziedzic))
### 🧹 Chores
- Print friendly error msg in case account doesn't have required permission. ([#1867](https://github.com/expo/eas-cli/pull/1867) by [@firasrg](https://github.com/firasrg))
- Limit project file upload size to 2GB. ([#1928](https://github.com/expo/eas-cli/pull/1928) by [@khamilowicz](https://github.com/khamilowicz))
- Bump urql graphql client major version. ([#1936](https://github.com/expo/eas-cli/pull/1936) by [@quinlanj](https://github.com/quinlanj))
## [3.15.1](https://github.com/expo/eas-cli/releases/tag/v3.15.1) - 2023-07-11
### 🐛 Bug fixes
- Ensure useClassicUpdates is not set when using EAS Update commands. ([#1915](https://github.com/expo/eas-cli/pull/1915) by [@ide](https://github.com/ide))
- Handle multiple GraphQLErrors when receiving a CombinedError. ([#1924](https://github.com/expo/eas-cli/pull/1924) by [@radoslawkrzemien](https://github.com/radoslawkrzemien))
+1 -1
View File
@@ -1,6 +1,6 @@
{
"npmClient": "yarn",
"useWorkspaces": true,
"version": "3.15.1",
"version": "3.17.0",
"$schema": "node_modules/lerna/schemas/lerna-schema.json"
}
+1
View File
@@ -6,6 +6,7 @@
],
"scripts": {
"build": "lerna run build",
"build-ci": "lerna run build-ci",
"build:tarballs:linux": "yarn build-for-size-check",
"build-for-size-check": "yarn build && yarn workspace eas-cli pretarball-ci && CLI_SIZE_CHECK=1 yarn workspace eas-cli oclif pack:tarballs --no-xz --targets linux-x64",
"typecheck": "lerna run typecheck",
+55 -55
View File
@@ -133,7 +133,7 @@ ALIASES
$ eas login
```
_See code: [src/commands/account/login.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/account/login.ts)_
_See code: [src/commands/account/login.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/account/login.ts)_
## `eas account:logout`
@@ -150,7 +150,7 @@ ALIASES
$ eas logout
```
_See code: [src/commands/account/logout.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/account/logout.ts)_
_See code: [src/commands/account/logout.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/account/logout.ts)_
## `eas account:view`
@@ -167,7 +167,7 @@ ALIASES
$ eas whoami
```
_See code: [src/commands/account/view.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/account/view.ts)_
_See code: [src/commands/account/view.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/account/view.ts)_
## `eas analytics [STATUS]`
@@ -181,7 +181,7 @@ DESCRIPTION
display or change analytics settings
```
_See code: [src/commands/analytics.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/analytics.ts)_
_See code: [src/commands/analytics.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/analytics.ts)_
## `eas autocomplete [SHELL]`
@@ -231,7 +231,7 @@ DESCRIPTION
create a branch
```
_See code: [src/commands/branch/create.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/branch/create.ts)_
_See code: [src/commands/branch/create.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/branch/create.ts)_
## `eas branch:delete [NAME]`
@@ -252,7 +252,7 @@ DESCRIPTION
delete a branch
```
_See code: [src/commands/branch/delete.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/branch/delete.ts)_
_See code: [src/commands/branch/delete.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/branch/delete.ts)_
## `eas branch:list`
@@ -272,7 +272,7 @@ DESCRIPTION
list all branches
```
_See code: [src/commands/branch/list.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/branch/list.ts)_
_See code: [src/commands/branch/list.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/branch/list.ts)_
## `eas branch:rename`
@@ -292,7 +292,7 @@ DESCRIPTION
rename a branch
```
_See code: [src/commands/branch/rename.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/branch/rename.ts)_
_See code: [src/commands/branch/rename.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/branch/rename.ts)_
## `eas branch:view [NAME]`
@@ -315,7 +315,7 @@ DESCRIPTION
view a branch
```
_See code: [src/commands/branch/view.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/branch/view.ts)_
_See code: [src/commands/branch/view.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/branch/view.ts)_
## `eas build`
@@ -345,7 +345,7 @@ DESCRIPTION
start a build
```
_See code: [src/commands/build/index.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/build/index.ts)_
_See code: [src/commands/build/index.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/build/index.ts)_
## `eas build:cancel [BUILD_ID]`
@@ -362,7 +362,7 @@ DESCRIPTION
cancel a build
```
_See code: [src/commands/build/cancel.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/build/cancel.ts)_
_See code: [src/commands/build/cancel.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/build/cancel.ts)_
## `eas build:configure`
@@ -379,7 +379,7 @@ DESCRIPTION
configure the project to support EAS Build
```
_See code: [src/commands/build/configure.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/build/configure.ts)_
_See code: [src/commands/build/configure.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/build/configure.ts)_
## `eas build:inspect`
@@ -414,7 +414,7 @@ DESCRIPTION
inspect the state of the project at specific build stages, useful for troubleshooting
```
_See code: [src/commands/build/inspect.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/build/inspect.ts)_
_See code: [src/commands/build/inspect.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/build/inspect.ts)_
## `eas build:list`
@@ -452,7 +452,7 @@ DESCRIPTION
list all builds for your project
```
_See code: [src/commands/build/list.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/build/list.ts)_
_See code: [src/commands/build/list.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/build/list.ts)_
## `eas build:resign`
@@ -478,7 +478,7 @@ DESCRIPTION
re-sign a build archive
```
_See code: [src/commands/build/resign.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/build/resign.ts)_
_See code: [src/commands/build/resign.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/build/resign.ts)_
## `eas build:run`
@@ -502,7 +502,7 @@ DESCRIPTION
run simulator/emulator builds from eas-cli
```
_See code: [src/commands/build/run.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/build/run.ts)_
_See code: [src/commands/build/run.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/build/run.ts)_
## `eas build:submit`
@@ -551,7 +551,7 @@ DESCRIPTION
get the latest version from EAS servers
```
_See code: [src/commands/build/version/get.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/build/version/get.ts)_
_See code: [src/commands/build/version/get.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/build/version/get.ts)_
## `eas build:version:set`
@@ -570,7 +570,7 @@ DESCRIPTION
update version of an app
```
_See code: [src/commands/build/version/set.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/build/version/set.ts)_
_See code: [src/commands/build/version/set.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/build/version/set.ts)_
## `eas build:version:sync`
@@ -589,7 +589,7 @@ DESCRIPTION
update a version in native code with a value stored on EAS servers
```
_See code: [src/commands/build/version/sync.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/build/version/sync.ts)_
_See code: [src/commands/build/version/sync.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/build/version/sync.ts)_
## `eas build:view [BUILD_ID]`
@@ -606,7 +606,7 @@ DESCRIPTION
view a build for your project
```
_See code: [src/commands/build/view.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/build/view.ts)_
_See code: [src/commands/build/view.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/build/view.ts)_
## `eas channel:create [NAME]`
@@ -627,7 +627,7 @@ DESCRIPTION
create a channel
```
_See code: [src/commands/channel/create.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/channel/create.ts)_
_See code: [src/commands/channel/create.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/channel/create.ts)_
## `eas channel:edit [NAME]`
@@ -649,7 +649,7 @@ DESCRIPTION
point a channel at a new branch
```
_See code: [src/commands/channel/edit.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/channel/edit.ts)_
_See code: [src/commands/channel/edit.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/channel/edit.ts)_
## `eas channel:list`
@@ -669,7 +669,7 @@ DESCRIPTION
list all channels
```
_See code: [src/commands/channel/list.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/channel/list.ts)_
_See code: [src/commands/channel/list.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/channel/list.ts)_
## `eas channel:rollout [CHANNEL]`
@@ -693,7 +693,7 @@ DESCRIPTION
Roll a new branch out on a channel incrementally.
```
_See code: [src/commands/channel/rollout.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/channel/rollout.ts)_
_See code: [src/commands/channel/rollout.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/channel/rollout.ts)_
## `eas channel:view [NAME]`
@@ -716,7 +716,7 @@ DESCRIPTION
view a channel
```
_See code: [src/commands/channel/view.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/channel/view.ts)_
_See code: [src/commands/channel/view.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/channel/view.ts)_
## `eas config`
@@ -737,7 +737,7 @@ DESCRIPTION
display project configuration (app.json + eas.json)
```
_See code: [src/commands/config.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/config.ts)_
_See code: [src/commands/config.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/config.ts)_
## `eas credentials`
@@ -754,7 +754,7 @@ DESCRIPTION
manage credentials
```
_See code: [src/commands/credentials.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/credentials.ts)_
_See code: [src/commands/credentials.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/credentials.ts)_
## `eas device:create`
@@ -768,7 +768,7 @@ DESCRIPTION
register new Apple Devices to use for internal distribution
```
_See code: [src/commands/device/create.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/device/create.ts)_
_See code: [src/commands/device/create.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/device/create.ts)_
## `eas device:delete`
@@ -788,7 +788,7 @@ DESCRIPTION
remove a registered device from your account
```
_See code: [src/commands/device/delete.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/device/delete.ts)_
_See code: [src/commands/device/delete.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/device/delete.ts)_
## `eas device:list`
@@ -809,7 +809,7 @@ DESCRIPTION
list all registered devices for your account
```
_See code: [src/commands/device/list.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/device/list.ts)_
_See code: [src/commands/device/list.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/device/list.ts)_
## `eas device:rename`
@@ -830,7 +830,7 @@ DESCRIPTION
rename a registered device
```
_See code: [src/commands/device/rename.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/device/rename.ts)_
_See code: [src/commands/device/rename.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/device/rename.ts)_
## `eas device:view [UDID]`
@@ -844,7 +844,7 @@ DESCRIPTION
view a device for your project
```
_See code: [src/commands/device/view.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/device/view.ts)_
_See code: [src/commands/device/view.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/device/view.ts)_
## `eas diagnostics`
@@ -858,7 +858,7 @@ DESCRIPTION
display environment info
```
_See code: [src/commands/diagnostics.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/diagnostics.ts)_
_See code: [src/commands/diagnostics.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/diagnostics.ts)_
## `eas help [COMMAND]`
@@ -946,7 +946,7 @@ DESCRIPTION
validate the local store configuration
```
_See code: [src/commands/metadata/lint.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/metadata/lint.ts)_
_See code: [src/commands/metadata/lint.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/metadata/lint.ts)_
## `eas metadata:pull`
@@ -963,7 +963,7 @@ DESCRIPTION
generate the local store configuration from the app stores
```
_See code: [src/commands/metadata/pull.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/metadata/pull.ts)_
_See code: [src/commands/metadata/pull.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/metadata/pull.ts)_
## `eas metadata:push`
@@ -980,7 +980,7 @@ DESCRIPTION
sync the local store configuration to the app stores
```
_See code: [src/commands/metadata/push.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/metadata/push.ts)_
_See code: [src/commands/metadata/push.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/metadata/push.ts)_
## `eas open`
@@ -994,7 +994,7 @@ DESCRIPTION
open the project page in a web browser
```
_See code: [src/commands/open.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/open.ts)_
_See code: [src/commands/open.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/open.ts)_
## `eas project:info`
@@ -1008,7 +1008,7 @@ DESCRIPTION
information about the current project
```
_See code: [src/commands/project/info.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/project/info.ts)_
_See code: [src/commands/project/info.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/project/info.ts)_
## `eas project:init`
@@ -1030,7 +1030,7 @@ ALIASES
$ eas init
```
_See code: [src/commands/project/init.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/project/init.ts)_
_See code: [src/commands/project/init.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/project/init.ts)_
## `eas secret:create`
@@ -1053,7 +1053,7 @@ DESCRIPTION
create an environment secret on the current project or owner account
```
_See code: [src/commands/secret/create.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/secret/create.ts)_
_See code: [src/commands/secret/create.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/secret/create.ts)_
## `eas secret:delete`
@@ -1071,7 +1071,7 @@ DESCRIPTION
delete an environment secret by ID
```
_See code: [src/commands/secret/delete.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/secret/delete.ts)_
_See code: [src/commands/secret/delete.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/secret/delete.ts)_
## `eas secret:list`
@@ -1085,7 +1085,7 @@ DESCRIPTION
list environment secrets available for your current app
```
_See code: [src/commands/secret/list.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/secret/list.ts)_
_See code: [src/commands/secret/list.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/secret/list.ts)_
## `eas secret:push`
@@ -1105,7 +1105,7 @@ DESCRIPTION
read environment secrets from env file and store on the server
```
_See code: [src/commands/secret/push.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/secret/push.ts)_
_See code: [src/commands/secret/push.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/secret/push.ts)_
## `eas submit`
@@ -1135,7 +1135,7 @@ ALIASES
$ eas build:submit
```
_See code: [src/commands/submit.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/submit.ts)_
_See code: [src/commands/submit.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/submit.ts)_
## `eas update`
@@ -1168,7 +1168,7 @@ DESCRIPTION
publish an update group
```
_See code: [src/commands/update/index.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/update/index.ts)_
_See code: [src/commands/update/index.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/update/index.ts)_
## `eas update:configure`
@@ -1186,7 +1186,7 @@ DESCRIPTION
configure the project to support EAS Update
```
_See code: [src/commands/update/configure.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/update/configure.ts)_
_See code: [src/commands/update/configure.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/update/configure.ts)_
## `eas update:delete GROUPID`
@@ -1207,7 +1207,7 @@ DESCRIPTION
delete all the updates in an update group
```
_See code: [src/commands/update/delete.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/update/delete.ts)_
_See code: [src/commands/update/delete.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/update/delete.ts)_
## `eas update:list`
@@ -1229,7 +1229,7 @@ DESCRIPTION
view the recent updates
```
_See code: [src/commands/update/list.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/update/list.ts)_
_See code: [src/commands/update/list.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/update/list.ts)_
## `eas update:republish`
@@ -1253,7 +1253,7 @@ DESCRIPTION
roll back to an existing update
```
_See code: [src/commands/update/republish.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/update/republish.ts)_
_See code: [src/commands/update/republish.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/update/republish.ts)_
## `eas update:view GROUPID`
@@ -1273,7 +1273,7 @@ DESCRIPTION
update group details
```
_See code: [src/commands/update/view.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/update/view.ts)_
_See code: [src/commands/update/view.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/update/view.ts)_
## `eas webhook:create`
@@ -1294,7 +1294,7 @@ DESCRIPTION
create a webhook
```
_See code: [src/commands/webhook/create.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/webhook/create.ts)_
_See code: [src/commands/webhook/create.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/webhook/create.ts)_
## `eas webhook:delete [ID]`
@@ -1314,7 +1314,7 @@ DESCRIPTION
delete a webhook
```
_See code: [src/commands/webhook/delete.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/webhook/delete.ts)_
_See code: [src/commands/webhook/delete.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/webhook/delete.ts)_
## `eas webhook:list`
@@ -1332,7 +1332,7 @@ DESCRIPTION
list webhooks
```
_See code: [src/commands/webhook/list.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/webhook/list.ts)_
_See code: [src/commands/webhook/list.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/webhook/list.ts)_
## `eas webhook:update`
@@ -1354,7 +1354,7 @@ DESCRIPTION
update a webhook
```
_See code: [src/commands/webhook/update.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/webhook/update.ts)_
_See code: [src/commands/webhook/update.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/webhook/update.ts)_
## `eas webhook:view ID`
@@ -1371,7 +1371,7 @@ DESCRIPTION
view a webhook
```
_See code: [src/commands/webhook/view.ts](https://github.com/expo/eas-cli/blob/v3.15.1/packages/eas-cli/src/commands/webhook/view.ts)_
_See code: [src/commands/webhook/view.ts](https://github.com/expo/eas-cli/blob/v3.17.0/packages/eas-cli/src/commands/webhook/view.ts)_
## `eas whoami`
+412 -163
View File
@@ -1213,6 +1213,22 @@
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "isSSOEnabled",
"description": "Whether this account has SSO enabled. Can be queried by all members.",
"args": [],
"type": {
"kind": "NON_NULL",
"name": null,
"ofType": {
"kind": "SCALAR",
"name": "Boolean",
"ofType": null
}
},
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "name",
"description": null,
@@ -2556,18 +2572,6 @@
"name": "AccountSSOConfiguration",
"description": "Auth configuration data for an SSO account.",
"fields": [
{
"name": "authEndpoint",
"description": null,
"args": [],
"type": {
"kind": "SCALAR",
"name": "String",
"ofType": null
},
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "authProtocol",
"description": null,
@@ -2648,18 +2652,6 @@
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "endSessionEndpoint",
"description": null,
"args": [],
"type": {
"kind": "SCALAR",
"name": "String",
"ofType": null
},
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "id",
"description": null,
@@ -2692,42 +2684,6 @@
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "jwksEndpoint",
"description": null,
"args": [],
"type": {
"kind": "SCALAR",
"name": "String",
"ofType": null
},
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "revokeEndpoint",
"description": null,
"args": [],
"type": {
"kind": "SCALAR",
"name": "String",
"ofType": null
},
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "tokenEndpoint",
"description": null,
"args": [],
"type": {
"kind": "SCALAR",
"name": "String",
"ofType": null
},
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "updatedAt",
"description": null,
@@ -2743,18 +2699,6 @@
},
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "userInfoEndpoint",
"description": null,
"args": [],
"type": {
"kind": "SCALAR",
"name": "String",
"ofType": null
},
"isDeprecated": false,
"deprecationReason": null
}
],
"inputFields": null,
@@ -3072,18 +3016,6 @@
"name": "AccountSSOConfigurationPublicData",
"description": "Public auth configuration data for an SSO account.",
"fields": [
{
"name": "authEndpoint",
"description": null,
"args": [],
"type": {
"kind": "SCALAR",
"name": "String",
"ofType": null
},
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "authProtocol",
"description": null,
@@ -3117,7 +3049,7 @@
"deprecationReason": null
},
{
"name": "clientIdentifier",
"name": "authorizationUrl",
"description": null,
"args": [],
"type": {
@@ -3132,18 +3064,6 @@
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "endSessionEndpoint",
"description": null,
"args": [],
"type": {
"kind": "SCALAR",
"name": "String",
"ofType": null
},
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "id",
"description": null,
@@ -3175,54 +3095,6 @@
},
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "jwksEndpoint",
"description": null,
"args": [],
"type": {
"kind": "SCALAR",
"name": "String",
"ofType": null
},
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "revokeEndpoint",
"description": null,
"args": [],
"type": {
"kind": "SCALAR",
"name": "String",
"ofType": null
},
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "tokenEndpoint",
"description": null,
"args": [],
"type": {
"kind": "SCALAR",
"name": "String",
"ofType": null
},
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "userInfoEndpoint",
"description": null,
"args": [],
"type": {
"kind": "SCALAR",
"name": "String",
"ofType": null
},
"isDeprecated": false,
"deprecationReason": null
}
],
"inputFields": null,
@@ -6499,6 +6371,18 @@
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "rollout",
"description": null,
"args": [],
"type": {
"kind": "SCALAR",
"name": "Float",
"ofType": null
},
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "track",
"description": null,
@@ -6599,6 +6483,18 @@
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "rollout",
"description": null,
"type": {
"kind": "SCALAR",
"name": "Float",
"ofType": null
},
"defaultValue": null,
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "track",
"description": null,
@@ -13729,6 +13625,12 @@
"description": null,
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "VOID",
"description": null,
"isDeprecated": false,
"deprecationReason": null
}
],
"possibleTypes": null
@@ -14318,6 +14220,22 @@
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "isWaived",
"description": null,
"args": [],
"type": {
"kind": "NON_NULL",
"name": null,
"ofType": {
"kind": "SCALAR",
"name": "Boolean",
"ofType": null
}
},
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "logFiles",
"description": null,
@@ -18658,6 +18576,33 @@
"enumValues": null,
"possibleTypes": null
},
{
"kind": "OBJECT",
"name": "DeleteSSOUserResult",
"description": null,
"fields": [
{
"name": "id",
"description": null,
"args": [],
"type": {
"kind": "NON_NULL",
"name": null,
"ofType": {
"kind": "SCALAR",
"name": "ID",
"ofType": null
}
},
"isDeprecated": false,
"deprecationReason": null
}
],
"inputFields": null,
"interfaces": [],
"enumValues": null,
"possibleTypes": null
},
{
"kind": "OBJECT",
"name": "DeleteUpdateBranchResult",
@@ -21375,9 +21320,13 @@
"description": null,
"args": [],
"type": {
"kind": "OBJECT",
"name": "GitHubRepositoryMetadata",
"ofType": null
"kind": "NON_NULL",
"name": null,
"ofType": {
"kind": "OBJECT",
"name": "GitHubRepositoryMetadata",
"ofType": null
}
},
"isDeprecated": false,
"deprecationReason": null
@@ -21513,18 +21462,6 @@
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "openGraphImageUrl",
"description": null,
"args": [],
"type": {
"kind": "SCALAR",
"name": "String",
"ofType": null
},
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "private",
"description": null,
@@ -25449,6 +25386,39 @@
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "deleteSSOUser",
"description": "Delete a SSO user. Actor must be an owner on the SSO user's SSO account.",
"args": [
{
"name": "ssoUserId",
"description": null,
"type": {
"kind": "NON_NULL",
"name": null,
"ofType": {
"kind": "SCALAR",
"name": "ID",
"ofType": null
}
},
"defaultValue": null,
"isDeprecated": false,
"deprecationReason": null
}
],
"type": {
"kind": "NON_NULL",
"name": null,
"ofType": {
"kind": "OBJECT",
"name": "DeleteSSOUserResult",
"ofType": null
}
},
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "deleteSecondFactorDevice",
"description": "Delete a second factor device",
@@ -26009,6 +25979,12 @@
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "BUILD_LIMIT_THRESHOLD_EXCEEDED",
"description": null,
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "BUILD_PLAN_CREDIT_THRESHOLD_EXCEEDED",
"description": null,
@@ -29318,6 +29294,22 @@
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "userActorPublicData",
"description": "Top-level query object for querying UserActorPublicData publicly.",
"args": [],
"type": {
"kind": "NON_NULL",
"name": null,
"ofType": {
"kind": "OBJECT",
"name": "UserActorPublicDataQuery",
"ofType": null
}
},
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "userByUserId",
"description": null,
@@ -34868,9 +34860,13 @@
"description": null,
"args": [],
"type": {
"kind": "SCALAR",
"name": "String",
"ofType": null
"kind": "NON_NULL",
"name": null,
"ofType": {
"kind": "SCALAR",
"name": "String",
"ofType": null
}
},
"isDeprecated": false,
"deprecationReason": null
@@ -35920,6 +35916,259 @@
}
]
},
{
"kind": "OBJECT",
"name": "UserActorPublicData",
"description": "A human user (type User or SSOUser) that can login to the Expo website, use Expo services, and be a member of accounts.",
"fields": [
{
"name": "apps",
"description": "Apps this user has published",
"args": [
{
"name": "includeUnpublished",
"description": null,
"type": {
"kind": "SCALAR",
"name": "Boolean",
"ofType": null
},
"defaultValue": null,
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "limit",
"description": null,
"type": {
"kind": "NON_NULL",
"name": null,
"ofType": {
"kind": "SCALAR",
"name": "Int",
"ofType": null
}
},
"defaultValue": null,
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "offset",
"description": null,
"type": {
"kind": "NON_NULL",
"name": null,
"ofType": {
"kind": "SCALAR",
"name": "Int",
"ofType": null
}
},
"defaultValue": null,
"isDeprecated": false,
"deprecationReason": null
}
],
"type": {
"kind": "NON_NULL",
"name": null,
"ofType": {
"kind": "LIST",
"name": null,
"ofType": {
"kind": "NON_NULL",
"name": null,
"ofType": {
"kind": "OBJECT",
"name": "App",
"ofType": null
}
}
}
},
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "firstName",
"description": null,
"args": [],
"type": {
"kind": "SCALAR",
"name": "String",
"ofType": null
},
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "id",
"description": null,
"args": [],
"type": {
"kind": "NON_NULL",
"name": null,
"ofType": {
"kind": "SCALAR",
"name": "ID",
"ofType": null
}
},
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "lastName",
"description": null,
"args": [],
"type": {
"kind": "SCALAR",
"name": "String",
"ofType": null
},
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "profilePhoto",
"description": null,
"args": [],
"type": {
"kind": "NON_NULL",
"name": null,
"ofType": {
"kind": "SCALAR",
"name": "String",
"ofType": null
}
},
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "snacks",
"description": "Snacks associated with this user's personal account",
"args": [
{
"name": "limit",
"description": null,
"type": {
"kind": "NON_NULL",
"name": null,
"ofType": {
"kind": "SCALAR",
"name": "Int",
"ofType": null
}
},
"defaultValue": null,
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "offset",
"description": null,
"type": {
"kind": "NON_NULL",
"name": null,
"ofType": {
"kind": "SCALAR",
"name": "Int",
"ofType": null
}
},
"defaultValue": null,
"isDeprecated": false,
"deprecationReason": null
}
],
"type": {
"kind": "NON_NULL",
"name": null,
"ofType": {
"kind": "LIST",
"name": null,
"ofType": {
"kind": "NON_NULL",
"name": null,
"ofType": {
"kind": "OBJECT",
"name": "Snack",
"ofType": null
}
}
}
},
"isDeprecated": false,
"deprecationReason": null
},
{
"name": "username",
"description": null,
"args": [],
"type": {
"kind": "NON_NULL",
"name": null,
"ofType": {
"kind": "SCALAR",
"name": "String",
"ofType": null
}
},
"isDeprecated": false,
"deprecationReason": null
}
],
"inputFields": null,
"interfaces": [],
"enumValues": null,
"possibleTypes": null
},
{
"kind": "OBJECT",
"name": "UserActorPublicDataQuery",
"description": null,
"fields": [
{
"name": "byUsername",
"description": "Get UserActorPublicData by username",
"args": [
{
"name": "username",
"description": null,
"type": {
"kind": "NON_NULL",
"name": null,
"ofType": {
"kind": "SCALAR",
"name": "String",
"ofType": null
}
},
"defaultValue": null,
"isDeprecated": false,
"deprecationReason": null
}
],
"type": {
"kind": "NON_NULL",
"name": null,
"ofType": {
"kind": "OBJECT",
"name": "UserActorPublicData",
"ofType": null
}
},
"isDeprecated": false,
"deprecationReason": null
}
],
"inputFields": null,
"interfaces": [],
"enumValues": null,
"possibleTypes": null
},
{
"kind": "OBJECT",
"name": "UserActorQuery",
+7 -7
View File
@@ -1,7 +1,7 @@
{
"name": "eas-cli",
"description": "EAS command line tool",
"version": "3.15.1",
"version": "3.17.0",
"author": "Expo <[email protected]>",
"bin": {
"eas": "./bin/run"
@@ -14,7 +14,7 @@
"@expo/config-plugins": "7.2.4",
"@expo/config-types": "49.0.0",
"@expo/eas-build-job": "1.0.13",
"@expo/eas-json": "3.15.1",
"@expo/eas-json": "3.17.0",
"@expo/json-file": "8.2.37",
"@expo/multipart-body-parser": "1.1.0",
"@expo/osascript": "2.0.33",
@@ -32,8 +32,8 @@
"@oclif/core": "1.23.2",
"@oclif/plugin-autocomplete": "1.3.10",
"@segment/ajv-human-errors": "^2.1.2",
"@urql/core": "3.1.1",
"@urql/exchange-retry": "1.0.0",
"@urql/core": "4.0.11",
"@urql/exchange-retry": "1.2.0",
"ajv": "8.11.0",
"ajv-formats": "2.1.1",
"better-opn": "3.0.2",
@@ -47,7 +47,6 @@
"fast-glob": "3.2.12",
"figures": "3.2.0",
"form-data": "4.0.0",
"freeport-async": "2.0.0",
"fs-extra": "10.1.0",
"getenv": "1.0.0",
"gradle-to-js": "2.0.1",
@@ -205,11 +204,12 @@
"scripts": {
"postpack": "rimraf oclif.manifest.json",
"prepack": "yarn rebuild && node ./scripts/prepack.js",
"rebuild": "rimraf build && yarn build",
"rebuild": "rimraf build && yarn build-ci",
"pretarball-ci": "./scripts/pretarball-ci.sh",
"build": "tsc --project tsconfig.build.json",
"build-ci": "tsc --project tsconfig.build-ci.json",
"watch": "yarn build --watch --preserveWatchOutput",
"typecheck": "tsc",
"typecheck": "tsc --project tsconfig.build-ci.json",
"test": "jest",
"version": "yarn oclif readme && node scripts/patch-readme && git add README.md",
"generate-graphql-code": "graphql-codegen --config graphql-codegen.yml",
-12
View File
@@ -2,7 +2,6 @@ import { JSONValue } from '@expo/json-file';
import { ApiV2Error } from './ApiV2Error';
import fetch, { RequestError, RequestInit } from './fetch';
import { getFreePortAsync } from './utils/port';
interface RequestOptions {
body: JSONValue;
@@ -105,14 +104,3 @@ export function getEASUpdateURL(projectId: string): string {
return new URL(projectId, `https://u.expo.dev`).href;
}
}
export async function getSsoLocalServerPortAsync(): Promise<number> {
let startPort: number;
if (process.env.SSO_LOCAL_SERVER_PORT) {
startPort = Number(process.env.SSO_LOCAL_SERVER_PORT);
} else {
startPort = 19300;
}
const port = await getFreePortAsync(startPort);
return port;
}
@@ -27,12 +27,18 @@ beforeEach(() => {
const EXPECTED_STRINGIFIED_GRAPHQL_ERROR_JSON = `[
{
"name": "GraphQLError",
"extensions": {},
"message": "Error 1"
},
{
"name": "GraphQLError",
"extensions": {},
"message": "Error 2"
},
{
"name": "GraphQLError",
"extensions": {},
"message": "Error 3"
}
]`;
+6
View File
@@ -45,6 +45,7 @@ import {
EasBuildFreeTierDisabledIOSError,
EasBuildFreeTierIosLimitExceededError,
EasBuildFreeTierLimitExceededError,
EasBuildLegacyResourceClassNotAvailableError,
EasBuildProjectArchiveUploadError,
EasBuildResourceClassNotAvailableInFreeTierError,
EasBuildTooManyPendingBuildsError,
@@ -190,6 +191,7 @@ const SERVER_SIDE_DEFINED_ERRORS: Record<string, typeof EasCommandError> = {
EAS_BUILD_FREE_TIER_IOS_LIMIT_EXCEEDED: EasBuildFreeTierIosLimitExceededError,
EAS_BUILD_RESOURCE_CLASS_NOT_AVAILABLE_IN_FREE_TIER:
EasBuildResourceClassNotAvailableInFreeTierError,
EAS_BUILD_LEGACY_RESOURCE_CLASS_NOT_AVAILABLE: EasBuildLegacyResourceClassNotAvailableError,
VALIDATION_ERROR: RequestValidationError,
};
@@ -255,6 +257,10 @@ async function uploadProjectAsync<TPlatform extends Platform>(
);
}
if (projectTarball.size > 2 * 1024 * 1024 * 1024) {
throw new Error('Project archive is too big. Maximum allowed size is 2GB.');
}
projectTarballPath = projectTarball.path;
const bucketKey = await uploadFileAtPathToGCSAsync(
+2
View File
@@ -14,6 +14,8 @@ export class EasBuildFreeTierIosLimitExceededError extends EasCommandError {}
export class EasBuildResourceClassNotAvailableInFreeTierError extends EasCommandError {}
export class EasBuildLegacyResourceClassNotAvailableError extends EasCommandError {}
export class RequestValidationError extends EasCommandError {}
export class EasBuildDownForMaintenanceError extends EasCommandError {}
@@ -0,0 +1,85 @@
import assert from 'assert';
// TODO(quin): move this into a common package with www
export type BranchMappingOperator =
| '=='
| '!='
| '<'
| '>'
| '<='
| '>='
| 'in'
| 'regex'
| 'hash_lt'
| 'hash_lte'
| 'hash_gt'
| 'hash_gte';
export type BranchMappingObject = {
clientKey: string;
branchMappingOperator: BranchMappingOperator;
operand: number | string | string[];
};
export type BranchMappingAlwaysTrue = 'true';
export type BranchMappingStatement =
| ['and' | 'or', ...BranchMappingNode[]]
| ['not', BranchMappingNode];
export type BranchMappingNode =
| BranchMappingAlwaysTrue
| BranchMappingObject
| BranchMappingStatement;
export type BranchMapping = {
version: number;
data: {
branchId: string;
branchMappingLogic: BranchMappingNode;
}[];
};
export function getNodesFromStatement(statement: BranchMappingStatement): BranchMappingNode[] {
return statement.slice(1) as BranchMappingNode[];
}
export function isAndStatement(
statement: BranchMappingStatement
): statement is BranchMappingStatement {
return statement[0] === 'and';
}
export function isStatement(node: BranchMappingNode): node is BranchMappingStatement {
return Array.isArray(node);
}
export function isNodeObject(node: BranchMappingNode): node is BranchMappingObject {
return typeof node === 'object' && !isStatement(node);
}
export function andStatement(nodes: BranchMappingNode[]): ['and', ...BranchMappingNode[]] {
return ['and', ...nodes];
}
export function isAlwaysTrue(node: BranchMappingNode): boolean {
return node === 'true';
}
export function alwaysTrue(): BranchMappingAlwaysTrue {
return 'true';
}
export function equalsOperator(): BranchMappingOperator {
return '==';
}
export function hashLtOperator(): BranchMappingOperator {
return 'hash_lt';
}
export function assertNodeObject(node: BranchMappingNode): asserts node is BranchMappingObject {
assert(
isNodeObject(node),
'Branch mapping node must be an object. Received: ' + JSON.stringify(node)
);
}
export function assertNumber(operand: string | number | string[]): asserts operand is number {
assert(typeof operand === 'number', 'Expected a number. Received: ' + JSON.stringify(operand));
}
+33 -17
View File
@@ -1,25 +1,14 @@
import assert from 'assert';
import chalk from 'chalk';
import { UpdateChannelObject } from '../graphql/queries/ChannelQuery';
import { UpdateBranchObject, UpdateChannelObject } from '../graphql/queries/ChannelQuery';
import Log from '../log';
import {
FormattedBranchDescription,
formatBranch,
getUpdateGroupDescriptionsWithBranch,
} from '../update/utils';
export type BranchMapping = {
version: number;
data: {
branchId: string;
branchMappingLogic: {
operand: number;
clientKey: string;
branchMappingOperator: string;
} & string;
}[];
};
import { BranchMapping, assertNodeObject, assertNumber, isNodeObject } from './branch-mapping';
/**
* Get the branch mapping and determine whether it is a rollout.
@@ -46,8 +35,12 @@ export function getBranchMapping(branchMappingString?: string): {
}
const isRollout = branchMapping.data.length === 2;
const rolloutPercent = branchMapping.data[0]?.branchMappingLogic.operand;
const branchMappingNode = branchMapping.data[0]?.branchMappingLogic;
let rolloutPercent: number | undefined;
if (isNodeObject(branchMappingNode)) {
assertNumber(branchMappingNode.operand);
rolloutPercent = branchMappingNode.operand;
}
switch (branchMapping.data.length) {
case 0:
break;
@@ -57,10 +50,11 @@ export function getBranchMapping(branchMappingString?: string): {
}
break;
case 2:
if (branchMapping.data[0].branchMappingLogic.clientKey !== 'rolloutToken') {
assertNodeObject(branchMappingNode);
if (branchMappingNode.clientKey !== 'rolloutToken') {
throw new Error('Client key of initial branch mapping must be "rolloutToken"');
}
if (branchMapping.data[0].branchMappingLogic.branchMappingOperator !== 'hash_lt') {
if (branchMappingNode.branchMappingOperator !== 'hash_lt') {
throw new Error('Branch mapping operator of initial branch mapping must be "hash_lt"');
}
if (rolloutPercent == null) {
@@ -115,3 +109,25 @@ export function logChannelDetails(channel: UpdateChannelObject): void {
);
}
}
function getUpdateBranchNullable(
channel: UpdateChannelObject,
branchId: string
): UpdateBranchObject | null {
const updateBranches = channel.updateBranches;
const updateBranch = updateBranches.find(branch => branch.id === branchId);
return updateBranch ?? null;
}
export function getUpdateBranch(
channel: UpdateChannelObject,
branchId: string
): UpdateBranchObject {
const updateBranch = getUpdateBranchNullable(channel, branchId);
if (!updateBranch) {
throw new Error(
`Could not find branch with id "${branchId}" in branch-mapping of channel "${channel.name}"`
);
}
return updateBranch;
}
@@ -200,7 +200,14 @@ export default abstract class EasCommand extends Command {
const requestIdLine = graphQLError.extensions?.requestId
? `\nRequest ID: ${err.graphQLErrors[0].extensions.requestId}`
: '';
return `${messageLine}${requestIdLine}`;
const defaultMsg = `${messageLine}${requestIdLine}`;
if (graphQLError.extensions?.errorCode === 'UNAUTHORIZED_ERROR') {
return `You don't have the required permissions to perform this operation.\n\n${defaultMsg}`;
}
return defaultMsg;
})
.join('\n');
Log.error(cleanMessage);
@@ -3,11 +3,10 @@ import {
Client,
OperationContext,
OperationResult,
PromisifiedSource,
OperationResultSource,
TypedDocumentNode,
cacheExchange,
createClient as createUrqlClient,
dedupExchange,
fetchExchange,
} from '@urql/core';
import { retryExchange } from '@urql/exchange-retry';
@@ -22,7 +21,7 @@ export interface ExpoGraphqlClient extends Client {
query: DocumentNode | TypedDocumentNode<Data, Variables> | string,
variables: Variables,
context: Partial<OperationContext> & { additionalTypenames: string[] }
): PromisifiedSource<OperationResult<Data, Variables>>;
): OperationResultSource<OperationResult<Data, Variables>>;
}
export function createGraphqlClient(authInfo: {
@@ -32,7 +31,6 @@ export function createGraphqlClient(authInfo: {
return createUrqlClient({
url: getExpoApiBaseUrl() + '/graphql',
exchanges: [
dedupExchange,
cacheExchange,
retryExchange({
maxDelayMs: 4000,
@@ -13,14 +13,14 @@ import {
UpdateChannelBranchMappingMutationVariables,
} from '../../graphql/generated';
import { BranchQuery } from '../../graphql/queries/BranchQuery';
import { ChannelQuery } from '../../graphql/queries/ChannelQuery';
import { ChannelQuery, UpdateChannelBasicInfo } from '../../graphql/queries/ChannelQuery';
import Log from '../../log';
import { enableJsonOutput, printJsonOnlyOutput } from '../../utils/json';
export async function updateChannelBranchMappingAsync(
graphqlClient: ExpoGraphqlClient,
{ channelId, branchMapping }: UpdateChannelBranchMappingMutationVariables
): Promise<UpdateChannelBranchMappingMutation['updateChannel']['editUpdateChannel']> {
): Promise<UpdateChannelBasicInfo> {
const data = await withErrorHandlingAsync(
graphqlClient
.mutation<UpdateChannelBranchMappingMutation, UpdateChannelBranchMappingMutationVariables>(
@@ -2,14 +2,20 @@ import { Flags } from '@oclif/core';
import chalk from 'chalk';
import { selectBranchOnAppAsync } from '../../branch/queries';
import {
BranchMapping,
BranchMappingObject,
assertNodeObject,
assertNumber,
} from '../../channel/branch-mapping';
import { selectChannelOnAppAsync } from '../../channel/queries';
import { BranchMapping, getBranchMapping } from '../../channel/utils';
import { getBranchMapping } from '../../channel/utils';
import EasCommand from '../../commandUtils/EasCommand';
import { ExpoGraphqlClient } from '../../commandUtils/context/contextUtils/createGraphqlClient';
import { EasNonInteractiveAndJsonFlags } from '../../commandUtils/flags';
import { UpdateBranch } from '../../graphql/generated';
import { BranchQuery } from '../../graphql/queries/BranchQuery';
import { ChannelQuery, UpdateChannelByNameObject } from '../../graphql/queries/ChannelQuery';
import { ChannelQuery, UpdateChannelObject } from '../../graphql/queries/ChannelQuery';
import Log from '../../log';
import { getDisplayNameForProjectIdAsync } from '../../project/projectUtils';
import { promptAsync, selectAsync } from '../../prompts';
@@ -39,7 +45,7 @@ async function promptForRolloutPercentAsync({
return rolloutPercent;
}
function getRolloutInfo(channel: UpdateChannelByNameObject): {
function getRolloutInfo(channel: UpdateChannelObject): {
newBranch: Pick<UpdateBranch, 'name' | 'id'>;
oldBranch: Pick<UpdateBranch, 'name' | 'id'>;
currentPercent: number;
@@ -53,7 +59,10 @@ function getRolloutInfo(channel: UpdateChannelByNameObject): {
throw new Error(`Branch mapping rollout is missing a branch for channel "${channel.name}".`);
}
const currentPercent = 100 * branchMapping.data[0].branchMappingLogic.operand;
const branchMappingNode = branchMapping.data[0]?.branchMappingLogic;
assertNodeObject(branchMappingNode);
assertNumber(branchMappingNode.operand);
const currentPercent = 100 * branchMappingNode.operand;
return { newBranch, oldBranch, currentPercent };
}
@@ -75,7 +84,7 @@ async function startRolloutAsync(
projectId: string;
displayName: string;
currentBranchMapping: BranchMapping;
channel: UpdateChannelByNameObject;
channel: UpdateChannelObject;
nonInteractive: boolean;
}
): Promise<{
@@ -156,7 +165,7 @@ async function editRolloutAsync(
percent?: number;
nonInteractive: boolean;
currentBranchMapping: BranchMapping;
channel: UpdateChannelByNameObject;
channel: UpdateChannelObject;
}
): Promise<{
newChannelInfo: {
@@ -183,7 +192,7 @@ async function editRolloutAsync(
}
const newBranchMapping = { ...currentBranchMapping };
newBranchMapping.data[0].branchMappingLogic.operand = percent / 100;
(newBranchMapping.data[0].branchMappingLogic as BranchMappingObject).operand = percent / 100;
const newChannelInfo = await updateChannelBranchMappingAsync(graphqlClient, {
channelId: channel.id,
@@ -214,7 +223,7 @@ async function endRolloutAsync(
branchName?: string;
nonInteractive: boolean;
projectId: string;
channel: UpdateChannelByNameObject;
channel: UpdateChannelObject;
}
): Promise<{
newChannelInfo: {
@@ -5,10 +5,10 @@ import gql from 'graphql-tag';
import { ExpoGraphqlClient } from '../../../../../commandUtils/context/contextUtils/createGraphqlClient';
import { withErrorHandlingAsync } from '../../../../../graphql/client';
import {
AndroidAppBuildCredentials,
AndroidAppBuildCredentialsFragment,
AndroidAppBuildCredentialsInput,
CreateAndroidAppBuildCredentialsMutation,
SetDefaultAndroidAppBuildCredentialsMutation,
SetKeystoreMutation,
} from '../../../../../graphql/generated';
import { AndroidAppBuildCredentialsFragmentNode } from '../../../../../graphql/types/credentials/AndroidAppBuildCredentials';
@@ -62,9 +62,9 @@ export const AndroidAppBuildCredentialsMutation = {
): Promise<AndroidAppBuildCredentialsFragment> {
const data = await withErrorHandlingAsync(
graphqlClient
.mutation<AndroidAppBuildCredentials>(
.mutation<SetDefaultAndroidAppBuildCredentialsMutation>(
gql`
mutation AndroidAppBuildCredentialsMutation(
mutation SetDefaultAndroidAppBuildCredentialsMutation(
$androidAppBuildCredentialsId: ID!
$isDefault: Boolean!
) {
@@ -85,7 +85,7 @@ export const AndroidAppBuildCredentialsMutation = {
.toPromise()
);
assert(data, `GraphQL: 'setDefault' not defined in server response ${JSON.stringify(data)}}`);
return data;
return data.androidAppBuildCredentials.setDefault;
},
async setKeystoreAsync(
graphqlClient: ExpoGraphqlClient,
+90 -25
View File
@@ -112,6 +112,8 @@ export type Account = {
googleServiceAccountKeys: Array<GoogleServiceAccountKey>;
id: Scalars['ID'];
isCurrent: Scalars['Boolean'];
/** Whether this account has SSO enabled. Can be queried by all members. */
isSSOEnabled: Scalars['Boolean'];
name: Scalars['String'];
/** Offers set on this account */
offers?: Maybe<Array<Offer>>;
@@ -466,20 +468,14 @@ export type AccountQueryByNameArgs = {
/** Auth configuration data for an SSO account. */
export type AccountSsoConfiguration = {
__typename?: 'AccountSSOConfiguration';
authEndpoint?: Maybe<Scalars['String']>;
authProtocol: AuthProtocolType;
authProviderIdentifier: Scalars['String'];
clientIdentifier: Scalars['String'];
clientSecret: Scalars['String'];
createdAt: Scalars['DateTime'];
endSessionEndpoint?: Maybe<Scalars['String']>;
id: Scalars['ID'];
issuer: Scalars['String'];
jwksEndpoint?: Maybe<Scalars['String']>;
revokeEndpoint?: Maybe<Scalars['String']>;
tokenEndpoint?: Maybe<Scalars['String']>;
updatedAt: Scalars['DateTime'];
userInfoEndpoint?: Maybe<Scalars['String']>;
};
export type AccountSsoConfigurationData = {
@@ -526,17 +522,11 @@ export type AccountSsoConfigurationMutationUpdateAccountSsoConfigurationArgs = {
/** Public auth configuration data for an SSO account. */
export type AccountSsoConfigurationPublicData = {
__typename?: 'AccountSSOConfigurationPublicData';
authEndpoint?: Maybe<Scalars['String']>;
authProtocol: AuthProtocolType;
authProviderIdentifier: Scalars['String'];
clientIdentifier: Scalars['String'];
endSessionEndpoint?: Maybe<Scalars['String']>;
authorizationUrl: Scalars['String'];
id: Scalars['ID'];
issuer: Scalars['String'];
jwksEndpoint?: Maybe<Scalars['String']>;
revokeEndpoint?: Maybe<Scalars['String']>;
tokenEndpoint?: Maybe<Scalars['String']>;
userInfoEndpoint?: Maybe<Scalars['String']>;
};
export type AccountSsoConfigurationPublicDataQuery = {
@@ -972,6 +962,7 @@ export type AndroidSubmissionConfig = {
/** @deprecated archiveType is deprecated and will be null */
archiveType?: Maybe<SubmissionAndroidArchiveType>;
releaseStatus?: Maybe<SubmissionAndroidReleaseStatus>;
rollout?: Maybe<Scalars['Float']>;
track: SubmissionAndroidTrack;
};
@@ -982,6 +973,7 @@ export type AndroidSubmissionConfigInput = {
googleServiceAccountKeyId?: InputMaybe<Scalars['String']>;
googleServiceAccountKeyJson?: InputMaybe<Scalars['String']>;
releaseStatus?: InputMaybe<SubmissionAndroidReleaseStatus>;
rollout?: InputMaybe<Scalars['Float']>;
track: SubmissionAndroidTrack;
};
@@ -2009,7 +2001,8 @@ export type BackgroundJobReceiptQueryByIdArgs = {
};
export enum BackgroundJobResultType {
GithubBuild = 'GITHUB_BUILD'
GithubBuild = 'GITHUB_BUILD',
Void = 'VOID'
}
export enum BackgroundJobState {
@@ -2072,6 +2065,7 @@ export type Build = ActivityTimelineProjectActivity & BuildOrBuildJob & {
initiatingUser?: Maybe<User>;
iosEnterpriseProvisioning?: Maybe<BuildIosEnterpriseProvisioning>;
isGitWorkingTreeDirty?: Maybe<Scalars['Boolean']>;
isWaived: Scalars['Boolean'];
logFiles: Array<Scalars['String']>;
maxBuildTimeSeconds: Scalars['Int'];
/** Retry time starts after completedAt */
@@ -2704,6 +2698,11 @@ export type DeleteRobotResult = {
id: Scalars['ID'];
};
export type DeleteSsoUserResult = {
__typename?: 'DeleteSSOUserResult';
id: Scalars['ID'];
};
export type DeleteUpdateBranchResult = {
__typename?: 'DeleteUpdateBranchResult';
id: Scalars['ID'];
@@ -3099,7 +3098,7 @@ export type GitHubRepository = {
githubRepositoryIdentifier: Scalars['Int'];
githubRepositoryUrl?: Maybe<Scalars['String']>;
id: Scalars['ID'];
metadata?: Maybe<GitHubRepositoryMetadata>;
metadata: GitHubRepositoryMetadata;
nodeIdentifier: Scalars['String'];
};
@@ -3112,7 +3111,6 @@ export type GitHubRepositoryMetadata = {
githubRepoUrl: Scalars['String'];
lastPushed: Scalars['DateTime'];
lastUpdated: Scalars['DateTime'];
openGraphImageUrl?: Maybe<Scalars['String']>;
private: Scalars['Boolean'];
};
@@ -3628,6 +3626,8 @@ export type MeMutation = {
createAccount: Account;
/** Delete an Account created via createAccount */
deleteAccount: DeleteAccountResult;
/** Delete a SSO user. Actor must be an owner on the SSO user's SSO account. */
deleteSSOUser: DeleteSsoUserResult;
/** Delete a second factor device */
deleteSecondFactorDevice: SecondFactorBooleanResult;
/** Delete a Snack that the current user owns */
@@ -3680,6 +3680,11 @@ export type MeMutationDeleteAccountArgs = {
};
export type MeMutationDeleteSsoUserArgs = {
ssoUserId: Scalars['ID'];
};
export type MeMutationDeleteSecondFactorDeviceArgs = {
otp: Scalars['String'];
userSecondFactorDeviceId: Scalars['ID'];
@@ -3755,6 +3760,7 @@ export type MeteredBillingStatus = {
export enum NotificationEvent {
BuildComplete = 'BUILD_COMPLETE',
BuildLimitThresholdExceeded = 'BUILD_LIMIT_THRESHOLD_EXCEEDED',
BuildPlanCreditThresholdExceeded = 'BUILD_PLAN_CREDIT_THRESHOLD_EXCEEDED',
SubmissionComplete = 'SUBMISSION_COMPLETE'
}
@@ -4205,6 +4211,8 @@ export type RootQuery = {
user: UserQuery;
/** Top-level query object for querying UserActors. */
userActor: UserActorQuery;
/** Top-level query object for querying UserActorPublicData publicly. */
userActorPublicData: UserActorPublicDataQuery;
/** @deprecated Use 'byId' field under 'user'. */
userByUserId?: Maybe<User>;
/** @deprecated Use 'byUsername' field under 'user'. */
@@ -5016,7 +5024,7 @@ export type User = Actor & UserActor & {
/** Discord account linked to a user */
discordUser?: Maybe<DiscordUser>;
displayName: Scalars['String'];
email?: Maybe<Scalars['String']>;
email: Scalars['String'];
emailVerified: Scalars['Boolean'];
/**
* Server feature gate values for this actor, optionally filtering by desired gates.
@@ -5179,6 +5187,46 @@ export type UserActorSnacksArgs = {
offset: Scalars['Int'];
};
/** A human user (type User or SSOUser) that can login to the Expo website, use Expo services, and be a member of accounts. */
export type UserActorPublicData = {
__typename?: 'UserActorPublicData';
/** Apps this user has published */
apps: Array<App>;
firstName?: Maybe<Scalars['String']>;
id: Scalars['ID'];
lastName?: Maybe<Scalars['String']>;
profilePhoto: Scalars['String'];
/** Snacks associated with this user's personal account */
snacks: Array<Snack>;
username: Scalars['String'];
};
/** A human user (type User or SSOUser) that can login to the Expo website, use Expo services, and be a member of accounts. */
export type UserActorPublicDataAppsArgs = {
includeUnpublished?: InputMaybe<Scalars['Boolean']>;
limit: Scalars['Int'];
offset: Scalars['Int'];
};
/** A human user (type User or SSOUser) that can login to the Expo website, use Expo services, and be a member of accounts. */
export type UserActorPublicDataSnacksArgs = {
limit: Scalars['Int'];
offset: Scalars['Int'];
};
export type UserActorPublicDataQuery = {
__typename?: 'UserActorPublicDataQuery';
/** Get UserActorPublicData by username */
byUsername: UserActorPublicData;
};
export type UserActorPublicDataQueryByUsernameArgs = {
username: Scalars['String'];
};
export type UserActorQuery = {
__typename?: 'UserActorQuery';
/** Query a UserActor by ID */
@@ -5515,6 +5563,14 @@ export type CreateAndroidAppBuildCredentialsMutationVariables = Exact<{
export type CreateAndroidAppBuildCredentialsMutation = { __typename?: 'RootMutation', androidAppBuildCredentials: { __typename?: 'AndroidAppBuildCredentialsMutation', createAndroidAppBuildCredentials: { __typename?: 'AndroidAppBuildCredentials', id: string, isDefault: boolean, isLegacy: boolean, name: string, androidKeystore?: { __typename?: 'AndroidKeystore', id: string, type: AndroidKeystoreType, keystore: string, keystorePassword: string, keyAlias: string, keyPassword?: string | null, md5CertificateFingerprint?: string | null, sha1CertificateFingerprint?: string | null, sha256CertificateFingerprint?: string | null, createdAt: any, updatedAt: any } | null } } };
export type SetDefaultAndroidAppBuildCredentialsMutationVariables = Exact<{
androidAppBuildCredentialsId: Scalars['ID'];
isDefault: Scalars['Boolean'];
}>;
export type SetDefaultAndroidAppBuildCredentialsMutation = { __typename?: 'RootMutation', androidAppBuildCredentials: { __typename?: 'AndroidAppBuildCredentialsMutation', setDefault: { __typename?: 'AndroidAppBuildCredentials', id: string, isDefault: boolean, isLegacy: boolean, name: string, androidKeystore?: { __typename?: 'AndroidKeystore', id: string, type: AndroidKeystoreType, keystore: string, keystorePassword: string, keyAlias: string, keyPassword?: string | null, md5CertificateFingerprint?: string | null, sha1CertificateFingerprint?: string | null, sha256CertificateFingerprint?: string | null, createdAt: any, updatedAt: any } | null } } };
export type SetKeystoreMutationVariables = Exact<{
androidAppBuildCredentialsId: Scalars['ID'];
keystoreId: Scalars['ID'];
@@ -5998,7 +6054,7 @@ export type CreateAndroidSubmissionMutationVariables = Exact<{
}>;
export type CreateAndroidSubmissionMutation = { __typename?: 'RootMutation', submission: { __typename?: 'SubmissionMutation', createAndroidSubmission: { __typename?: 'CreateSubmissionResult', submission: { __typename?: 'Submission', id: string, status: SubmissionStatus, platform: AppPlatform, logsUrl?: string | null, app: { __typename?: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } }, androidConfig?: { __typename?: 'AndroidSubmissionConfig', applicationIdentifier?: string | null, track: SubmissionAndroidTrack, releaseStatus?: SubmissionAndroidReleaseStatus | null } | null, iosConfig?: { __typename?: 'IosSubmissionConfig', ascAppIdentifier: string, appleIdUsername?: string | null } | null, error?: { __typename?: 'SubmissionError', errorCode?: string | null, message?: string | null } | null } } } };
export type CreateAndroidSubmissionMutation = { __typename?: 'RootMutation', submission: { __typename?: 'SubmissionMutation', createAndroidSubmission: { __typename?: 'CreateSubmissionResult', submission: { __typename?: 'Submission', id: string, status: SubmissionStatus, platform: AppPlatform, logsUrl?: string | null, app: { __typename?: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } }, androidConfig?: { __typename?: 'AndroidSubmissionConfig', applicationIdentifier?: string | null, track: SubmissionAndroidTrack, releaseStatus?: SubmissionAndroidReleaseStatus | null, rollout?: number | null } | null, iosConfig?: { __typename?: 'IosSubmissionConfig', ascAppIdentifier: string, appleIdUsername?: string | null } | null, error?: { __typename?: 'SubmissionError', errorCode?: string | null, message?: string | null } | null } } } };
export type CreateIosSubmissionMutationVariables = Exact<{
appId: Scalars['ID'];
@@ -6008,7 +6064,7 @@ export type CreateIosSubmissionMutationVariables = Exact<{
}>;
export type CreateIosSubmissionMutation = { __typename?: 'RootMutation', submission: { __typename?: 'SubmissionMutation', createIosSubmission: { __typename?: 'CreateSubmissionResult', submission: { __typename?: 'Submission', id: string, status: SubmissionStatus, platform: AppPlatform, logsUrl?: string | null, app: { __typename?: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } }, androidConfig?: { __typename?: 'AndroidSubmissionConfig', applicationIdentifier?: string | null, track: SubmissionAndroidTrack, releaseStatus?: SubmissionAndroidReleaseStatus | null } | null, iosConfig?: { __typename?: 'IosSubmissionConfig', ascAppIdentifier: string, appleIdUsername?: string | null } | null, error?: { __typename?: 'SubmissionError', errorCode?: string | null, message?: string | null } | null } } } };
export type CreateIosSubmissionMutation = { __typename?: 'RootMutation', submission: { __typename?: 'SubmissionMutation', createIosSubmission: { __typename?: 'CreateSubmissionResult', submission: { __typename?: 'Submission', id: string, status: SubmissionStatus, platform: AppPlatform, logsUrl?: string | null, app: { __typename?: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } }, androidConfig?: { __typename?: 'AndroidSubmissionConfig', applicationIdentifier?: string | null, track: SubmissionAndroidTrack, releaseStatus?: SubmissionAndroidReleaseStatus | null, rollout?: number | null } | null, iosConfig?: { __typename?: 'IosSubmissionConfig', ascAppIdentifier: string, appleIdUsername?: string | null } | null, error?: { __typename?: 'SubmissionError', errorCode?: string | null, message?: string | null } | null } } } };
export type CreateUploadSessionMutationVariables = Exact<{
type: UploadSessionType;
@@ -6102,7 +6158,7 @@ export type BuildsWithSubmissionsByIdQueryVariables = Exact<{
}>;
export type BuildsWithSubmissionsByIdQuery = { __typename?: 'RootQuery', builds: { __typename?: 'BuildQuery', byId: { __typename?: 'Build', id: string, status: BuildStatus, platform: AppPlatform, channel?: string | null, releaseChannel?: string | null, distribution?: DistributionType | null, iosEnterpriseProvisioning?: BuildIosEnterpriseProvisioning | null, buildProfile?: string | null, sdkVersion?: string | null, appVersion?: string | null, appBuildVersion?: string | null, runtimeVersion?: string | null, gitCommitHash?: string | null, gitCommitMessage?: string | null, initialQueuePosition?: number | null, queuePosition?: number | null, estimatedWaitTimeLeftSeconds?: number | null, priority: BuildPriority, createdAt: any, updatedAt: any, message?: string | null, completedAt?: any | null, resourceClass: BuildResourceClass, expirationDate?: any | null, submissions: Array<{ __typename?: 'Submission', id: string, status: SubmissionStatus, platform: AppPlatform, logsUrl?: string | null, app: { __typename?: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } }, androidConfig?: { __typename?: 'AndroidSubmissionConfig', applicationIdentifier?: string | null, track: SubmissionAndroidTrack, releaseStatus?: SubmissionAndroidReleaseStatus | null } | null, iosConfig?: { __typename?: 'IosSubmissionConfig', ascAppIdentifier: string, appleIdUsername?: string | null } | null, error?: { __typename?: 'SubmissionError', errorCode?: string | null, message?: string | null } | null }>, error?: { __typename?: 'BuildError', errorCode: string, message: string, docsUrl?: string | null } | null, artifacts?: { __typename?: 'BuildArtifacts', buildUrl?: string | null, xcodeBuildLogsUrl?: string | null, applicationArchiveUrl?: string | null } | null, initiatingActor?: { __typename: 'Robot', id: string, displayName: string } | { __typename: 'SSOUser', id: string, displayName: string } | { __typename: 'User', id: string, displayName: string } | null, project: { __typename: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } } | { __typename: 'Snack', id: string, name: string, slug: string } } } };
export type BuildsWithSubmissionsByIdQuery = { __typename?: 'RootQuery', builds: { __typename?: 'BuildQuery', byId: { __typename?: 'Build', id: string, status: BuildStatus, platform: AppPlatform, channel?: string | null, releaseChannel?: string | null, distribution?: DistributionType | null, iosEnterpriseProvisioning?: BuildIosEnterpriseProvisioning | null, buildProfile?: string | null, sdkVersion?: string | null, appVersion?: string | null, appBuildVersion?: string | null, runtimeVersion?: string | null, gitCommitHash?: string | null, gitCommitMessage?: string | null, initialQueuePosition?: number | null, queuePosition?: number | null, estimatedWaitTimeLeftSeconds?: number | null, priority: BuildPriority, createdAt: any, updatedAt: any, message?: string | null, completedAt?: any | null, resourceClass: BuildResourceClass, expirationDate?: any | null, submissions: Array<{ __typename?: 'Submission', id: string, status: SubmissionStatus, platform: AppPlatform, logsUrl?: string | null, app: { __typename?: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } }, androidConfig?: { __typename?: 'AndroidSubmissionConfig', applicationIdentifier?: string | null, track: SubmissionAndroidTrack, releaseStatus?: SubmissionAndroidReleaseStatus | null, rollout?: number | null } | null, iosConfig?: { __typename?: 'IosSubmissionConfig', ascAppIdentifier: string, appleIdUsername?: string | null } | null, error?: { __typename?: 'SubmissionError', errorCode?: string | null, message?: string | null } | null }>, error?: { __typename?: 'BuildError', errorCode: string, message: string, docsUrl?: string | null } | null, artifacts?: { __typename?: 'BuildArtifacts', buildUrl?: string | null, xcodeBuildLogsUrl?: string | null, applicationArchiveUrl?: string | null } | null, initiatingActor?: { __typename: 'Robot', id: string, displayName: string } | { __typename: 'SSOUser', id: string, displayName: string } | { __typename: 'User', id: string, displayName: string } | null, project: { __typename: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } } | { __typename: 'Snack', id: string, name: string, slug: string } } } };
export type ViewBuildsOnAppQueryVariables = Exact<{
appId: Scalars['String'];
@@ -6129,7 +6185,16 @@ export type ViewUpdateChannelsOnAppQueryVariables = Exact<{
}>;
export type ViewUpdateChannelsOnAppQuery = { __typename?: 'RootQuery', app: { __typename?: 'AppQuery', byId: { __typename?: 'App', id: string, updateChannels: Array<{ __typename?: 'UpdateChannel', id: string, name: string, branchMapping: string, updateBranches: Array<{ __typename?: 'UpdateBranch', id: string, name: string, updateGroups: Array<Array<{ __typename?: 'Update', id: string, group: string, message?: string | null, createdAt: any, runtimeVersion: string, platform: string, manifestFragment: string, isRollBackToEmbedded: boolean, manifestPermalink: string, gitCommitHash?: string | null, actor?: { __typename: 'Robot', firstName?: string | null, id: string } | { __typename: 'SSOUser', username: string, id: string } | { __typename: 'User', username: string, id: string } | null, branch: { __typename?: 'UpdateBranch', id: string, name: string }, codeSigningInfo?: { __typename?: 'CodeSigningInfo', keyid: string, sig: string, alg: string } | null }>> }> }> } } };
export type ViewUpdateChannelsOnAppQuery = { __typename?: 'RootQuery', app: { __typename?: 'AppQuery', byId: { __typename?: 'App', id: string, updateChannels: Array<{ __typename?: 'UpdateChannel', id: string, name: string, createdAt: any, branchMapping: string, updateBranches: Array<{ __typename?: 'UpdateBranch', id: string, name: string, updateGroups: Array<Array<{ __typename?: 'Update', id: string, group: string, message?: string | null, createdAt: any, runtimeVersion: string, platform: string, manifestFragment: string, isRollBackToEmbedded: boolean, manifestPermalink: string, gitCommitHash?: string | null, actor?: { __typename: 'Robot', firstName?: string | null, id: string } | { __typename: 'SSOUser', username: string, id: string } | { __typename: 'User', username: string, id: string } | null, branch: { __typename?: 'UpdateBranch', id: string, name: string }, codeSigningInfo?: { __typename?: 'CodeSigningInfo', keyid: string, sig: string, alg: string } | null }>> }> }> } } };
export type ViewUpdateChannelsPaginatedOnAppQueryVariables = Exact<{
appId: Scalars['String'];
first?: InputMaybe<Scalars['Int']>;
after?: InputMaybe<Scalars['String']>;
}>;
export type ViewUpdateChannelsPaginatedOnAppQuery = { __typename?: 'RootQuery', app: { __typename?: 'AppQuery', byId: { __typename?: 'App', id: string, channelsPaginated: { __typename?: 'AppChannelsConnection', edges: Array<{ __typename?: 'AppChannelEdge', node: { __typename?: 'UpdateChannel', id: string, name: string, branchMapping: string } }>, pageInfo: { __typename?: 'PageInfo', hasNextPage: boolean, hasPreviousPage: boolean, startCursor?: string | null, endCursor?: string | null } } } } };
export type EnvironmentSecretsByAppIdQueryVariables = Exact<{
appId: Scalars['String'];
@@ -6164,7 +6229,7 @@ export type SubmissionsByIdQueryVariables = Exact<{
}>;
export type SubmissionsByIdQuery = { __typename?: 'RootQuery', submissions: { __typename?: 'SubmissionQuery', byId: { __typename?: 'Submission', id: string, status: SubmissionStatus, platform: AppPlatform, logsUrl?: string | null, app: { __typename?: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } }, androidConfig?: { __typename?: 'AndroidSubmissionConfig', applicationIdentifier?: string | null, track: SubmissionAndroidTrack, releaseStatus?: SubmissionAndroidReleaseStatus | null } | null, iosConfig?: { __typename?: 'IosSubmissionConfig', ascAppIdentifier: string, appleIdUsername?: string | null } | null, error?: { __typename?: 'SubmissionError', errorCode?: string | null, message?: string | null } | null } } };
export type SubmissionsByIdQuery = { __typename?: 'RootQuery', submissions: { __typename?: 'SubmissionQuery', byId: { __typename?: 'Submission', id: string, status: SubmissionStatus, platform: AppPlatform, logsUrl?: string | null, app: { __typename?: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } }, androidConfig?: { __typename?: 'AndroidSubmissionConfig', applicationIdentifier?: string | null, track: SubmissionAndroidTrack, releaseStatus?: SubmissionAndroidReleaseStatus | null, rollout?: number | null } | null, iosConfig?: { __typename?: 'IosSubmissionConfig', ascAppIdentifier: string, appleIdUsername?: string | null } | null, error?: { __typename?: 'SubmissionError', errorCode?: string | null, message?: string | null } | null } } };
export type GetAllSubmissionsForAppQueryVariables = Exact<{
appId: Scalars['String'];
@@ -6175,7 +6240,7 @@ export type GetAllSubmissionsForAppQueryVariables = Exact<{
}>;
export type GetAllSubmissionsForAppQuery = { __typename?: 'RootQuery', app: { __typename?: 'AppQuery', byId: { __typename?: 'App', id: string, submissions: Array<{ __typename?: 'Submission', id: string, status: SubmissionStatus, platform: AppPlatform, logsUrl?: string | null, app: { __typename?: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } }, androidConfig?: { __typename?: 'AndroidSubmissionConfig', applicationIdentifier?: string | null, track: SubmissionAndroidTrack, releaseStatus?: SubmissionAndroidReleaseStatus | null } | null, iosConfig?: { __typename?: 'IosSubmissionConfig', ascAppIdentifier: string, appleIdUsername?: string | null } | null, error?: { __typename?: 'SubmissionError', errorCode?: string | null, message?: string | null } | null }> } } };
export type GetAllSubmissionsForAppQuery = { __typename?: 'RootQuery', app: { __typename?: 'AppQuery', byId: { __typename?: 'App', id: string, submissions: Array<{ __typename?: 'Submission', id: string, status: SubmissionStatus, platform: AppPlatform, logsUrl?: string | null, app: { __typename?: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } }, androidConfig?: { __typename?: 'AndroidSubmissionConfig', applicationIdentifier?: string | null, track: SubmissionAndroidTrack, releaseStatus?: SubmissionAndroidReleaseStatus | null, rollout?: number | null } | null, iosConfig?: { __typename?: 'IosSubmissionConfig', ascAppIdentifier: string, appleIdUsername?: string | null } | null, error?: { __typename?: 'SubmissionError', errorCode?: string | null, message?: string | null } | null }> } } };
export type ViewUpdatesByGroupQueryVariables = Exact<{
groupId: Scalars['ID'];
@@ -6231,13 +6296,13 @@ export type AppFragment = { __typename?: 'App', id: string, fullName: string, sl
export type BuildFragment = { __typename?: 'Build', id: string, status: BuildStatus, platform: AppPlatform, channel?: string | null, releaseChannel?: string | null, distribution?: DistributionType | null, iosEnterpriseProvisioning?: BuildIosEnterpriseProvisioning | null, buildProfile?: string | null, sdkVersion?: string | null, appVersion?: string | null, appBuildVersion?: string | null, runtimeVersion?: string | null, gitCommitHash?: string | null, gitCommitMessage?: string | null, initialQueuePosition?: number | null, queuePosition?: number | null, estimatedWaitTimeLeftSeconds?: number | null, priority: BuildPriority, createdAt: any, updatedAt: any, message?: string | null, completedAt?: any | null, resourceClass: BuildResourceClass, expirationDate?: any | null, error?: { __typename?: 'BuildError', errorCode: string, message: string, docsUrl?: string | null } | null, artifacts?: { __typename?: 'BuildArtifacts', buildUrl?: string | null, xcodeBuildLogsUrl?: string | null, applicationArchiveUrl?: string | null } | null, initiatingActor?: { __typename: 'Robot', id: string, displayName: string } | { __typename: 'SSOUser', id: string, displayName: string } | { __typename: 'User', id: string, displayName: string } | null, project: { __typename: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } } | { __typename: 'Snack', id: string, name: string, slug: string } };
export type BuildWithSubmissionsFragment = { __typename?: 'Build', id: string, status: BuildStatus, platform: AppPlatform, channel?: string | null, releaseChannel?: string | null, distribution?: DistributionType | null, iosEnterpriseProvisioning?: BuildIosEnterpriseProvisioning | null, buildProfile?: string | null, sdkVersion?: string | null, appVersion?: string | null, appBuildVersion?: string | null, runtimeVersion?: string | null, gitCommitHash?: string | null, gitCommitMessage?: string | null, initialQueuePosition?: number | null, queuePosition?: number | null, estimatedWaitTimeLeftSeconds?: number | null, priority: BuildPriority, createdAt: any, updatedAt: any, message?: string | null, completedAt?: any | null, resourceClass: BuildResourceClass, expirationDate?: any | null, submissions: Array<{ __typename?: 'Submission', id: string, status: SubmissionStatus, platform: AppPlatform, logsUrl?: string | null, app: { __typename?: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } }, androidConfig?: { __typename?: 'AndroidSubmissionConfig', applicationIdentifier?: string | null, track: SubmissionAndroidTrack, releaseStatus?: SubmissionAndroidReleaseStatus | null } | null, iosConfig?: { __typename?: 'IosSubmissionConfig', ascAppIdentifier: string, appleIdUsername?: string | null } | null, error?: { __typename?: 'SubmissionError', errorCode?: string | null, message?: string | null } | null }>, error?: { __typename?: 'BuildError', errorCode: string, message: string, docsUrl?: string | null } | null, artifacts?: { __typename?: 'BuildArtifacts', buildUrl?: string | null, xcodeBuildLogsUrl?: string | null, applicationArchiveUrl?: string | null } | null, initiatingActor?: { __typename: 'Robot', id: string, displayName: string } | { __typename: 'SSOUser', id: string, displayName: string } | { __typename: 'User', id: string, displayName: string } | null, project: { __typename: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } } | { __typename: 'Snack', id: string, name: string, slug: string } };
export type BuildWithSubmissionsFragment = { __typename?: 'Build', id: string, status: BuildStatus, platform: AppPlatform, channel?: string | null, releaseChannel?: string | null, distribution?: DistributionType | null, iosEnterpriseProvisioning?: BuildIosEnterpriseProvisioning | null, buildProfile?: string | null, sdkVersion?: string | null, appVersion?: string | null, appBuildVersion?: string | null, runtimeVersion?: string | null, gitCommitHash?: string | null, gitCommitMessage?: string | null, initialQueuePosition?: number | null, queuePosition?: number | null, estimatedWaitTimeLeftSeconds?: number | null, priority: BuildPriority, createdAt: any, updatedAt: any, message?: string | null, completedAt?: any | null, resourceClass: BuildResourceClass, expirationDate?: any | null, submissions: Array<{ __typename?: 'Submission', id: string, status: SubmissionStatus, platform: AppPlatform, logsUrl?: string | null, app: { __typename?: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } }, androidConfig?: { __typename?: 'AndroidSubmissionConfig', applicationIdentifier?: string | null, track: SubmissionAndroidTrack, releaseStatus?: SubmissionAndroidReleaseStatus | null, rollout?: number | null } | null, iosConfig?: { __typename?: 'IosSubmissionConfig', ascAppIdentifier: string, appleIdUsername?: string | null } | null, error?: { __typename?: 'SubmissionError', errorCode?: string | null, message?: string | null } | null }>, error?: { __typename?: 'BuildError', errorCode: string, message: string, docsUrl?: string | null } | null, artifacts?: { __typename?: 'BuildArtifacts', buildUrl?: string | null, xcodeBuildLogsUrl?: string | null, applicationArchiveUrl?: string | null } | null, initiatingActor?: { __typename: 'Robot', id: string, displayName: string } | { __typename: 'SSOUser', id: string, displayName: string } | { __typename: 'User', id: string, displayName: string } | null, project: { __typename: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } } | { __typename: 'Snack', id: string, name: string, slug: string } };
export type EnvironmentSecretFragment = { __typename?: 'EnvironmentSecret', id: string, name: string, type: EnvironmentSecretType, createdAt: any };
export type StatuspageServiceFragment = { __typename?: 'StatuspageService', id: string, name: StatuspageServiceName, status: StatuspageServiceStatus, incidents: Array<{ __typename?: 'StatuspageIncident', id: string, status: StatuspageIncidentStatus, name: string, impact: StatuspageIncidentImpact, shortlink: string }> };
export type SubmissionFragment = { __typename?: 'Submission', id: string, status: SubmissionStatus, platform: AppPlatform, logsUrl?: string | null, app: { __typename?: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } }, androidConfig?: { __typename?: 'AndroidSubmissionConfig', applicationIdentifier?: string | null, track: SubmissionAndroidTrack, releaseStatus?: SubmissionAndroidReleaseStatus | null } | null, iosConfig?: { __typename?: 'IosSubmissionConfig', ascAppIdentifier: string, appleIdUsername?: string | null } | null, error?: { __typename?: 'SubmissionError', errorCode?: string | null, message?: string | null } | null };
export type SubmissionFragment = { __typename?: 'Submission', id: string, status: SubmissionStatus, platform: AppPlatform, logsUrl?: string | null, app: { __typename?: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } }, androidConfig?: { __typename?: 'AndroidSubmissionConfig', applicationIdentifier?: string | null, track: SubmissionAndroidTrack, releaseStatus?: SubmissionAndroidReleaseStatus | null, rollout?: number | null } | null, iosConfig?: { __typename?: 'IosSubmissionConfig', ascAppIdentifier: string, appleIdUsername?: string | null } | null, error?: { __typename?: 'SubmissionError', errorCode?: string | null, message?: string | null } | null };
export type UpdateFragment = { __typename?: 'Update', id: string, group: string, message?: string | null, createdAt: any, runtimeVersion: string, platform: string, manifestFragment: string, isRollBackToEmbedded: boolean, manifestPermalink: string, gitCommitHash?: string | null, actor?: { __typename: 'Robot', firstName?: string | null, id: string } | { __typename: 'SSOUser', username: string, id: string } | { __typename: 'User', username: string, id: string } | null, branch: { __typename?: 'UpdateBranch', id: string, name: string }, codeSigningInfo?: { __typename?: 'CodeSigningInfo', keyid: string, sig: string, alg: string } | null };
@@ -5,21 +5,33 @@ import { ChannelNotFoundError } from '../../channel/errors';
import { ExpoGraphqlClient } from '../../commandUtils/context/contextUtils/createGraphqlClient';
import { withErrorHandlingAsync } from '../client';
import {
PageInfo,
ViewUpdateChannelOnAppQuery,
ViewUpdateChannelOnAppQueryVariables,
ViewUpdateChannelsOnAppQuery,
ViewUpdateChannelsOnAppQueryVariables,
ViewUpdateChannelsPaginatedOnAppQuery,
ViewUpdateChannelsPaginatedOnAppQueryVariables,
} from '../generated';
import { UpdateFragmentNode } from '../types/Update';
export type UpdateChannelObject = NonNullable<
type ViewUpdateChannelsOnAppObject = NonNullable<
ViewUpdateChannelsOnAppQuery['app']['byId']['updateChannels']
>[number];
export type UpdateChannelByNameObject = NonNullable<
type UpdateChannelByNameObject = NonNullable<
ViewUpdateChannelOnAppQuery['app']['byId']['updateChannelByName']
>;
// this asserts they are the same thing
export type UpdateChannelObject = ViewUpdateChannelsOnAppObject & UpdateChannelByNameObject;
export type UpdateBranchObject = UpdateChannelObject['updateBranches'][number];
export type UpdateChannelBasicInfo = NonNullable<
ViewUpdateChannelsPaginatedOnAppQuery['app']['byId']['channelsPaginated']['edges'][0]['node']
>;
export const ChannelQuery = {
async viewUpdateChannelAsync(
graphqlClient: ExpoGraphqlClient,
@@ -80,6 +92,7 @@ export const ChannelQuery = {
updateChannels(offset: $offset, limit: $limit) {
id
name
createdAt
branchMapping
updateBranches(offset: 0, limit: 5) {
id
@@ -108,4 +121,51 @@ export const ChannelQuery = {
return updateChannels;
},
async viewUpdateChannelsBasicInfoPaginatedOnAppAsync(
graphqlClient: ExpoGraphqlClient,
{ appId, first, after }: ViewUpdateChannelsPaginatedOnAppQueryVariables
): Promise<[UpdateChannelBasicInfo[], PageInfo]> {
const response = await withErrorHandlingAsync(
graphqlClient
.query<
ViewUpdateChannelsPaginatedOnAppQuery,
ViewUpdateChannelsPaginatedOnAppQueryVariables
>(
gql`
query ViewUpdateChannelsPaginatedOnApp($appId: String!, $first: Int, $after: String) {
app {
byId(appId: $appId) {
id
channelsPaginated(first: $first, after: $after) {
edges {
node {
id
name
branchMapping
}
}
pageInfo {
hasNextPage
hasPreviousPage
startCursor
endCursor
}
}
}
}
}
`,
{ appId, first, after },
{ additionalTypenames: ['UpdateChannel', 'UpdateBranch', 'Update'] }
)
.toPromise()
);
const { channelsPaginated } = response.app.byId;
if (!channelsPaginated) {
throw new Error(`Could not find channels on project with id ${appId}`);
}
return [channelsPaginated.edges.map(edge => edge.node) ?? [], channelsPaginated.pageInfo];
},
};
@@ -18,6 +18,7 @@ export const SubmissionFragmentNode = gql`
applicationIdentifier
track
releaseStatus
rollout
}
iosConfig {
ascAppIdentifier
@@ -3,6 +3,7 @@ import { JSONObject } from '@expo/json-file';
import { getPrebuildConfigAsync } from '@expo/prebuild-config';
import { readPlistAsync } from '../../utils/plist';
import { hasIgnoredIosProjectAsync } from '../workflow';
interface Target {
buildConfiguration?: string;
@@ -13,6 +14,7 @@ export async function getManagedApplicationTargetEntitlementsAsync(
env: Record<string, string>
): Promise<JSONObject> {
const originalProcessEnv: NodeJS.ProcessEnv = process.env;
try {
process.env = {
...process.env,
@@ -24,6 +26,7 @@ export async function getManagedApplicationTargetEntitlementsAsync(
projectRoot: projectDir,
platforms: ['ios'],
introspect: true,
ignoreExistingNativeFiles: await hasIgnoredIosProjectAsync(projectDir),
});
return expWithMods.ios?.entitlements || {};
} finally {
+12
View File
@@ -44,3 +44,15 @@ export async function resolveWorkflowPerPlatformAsync(
]);
return { android, ios };
}
export async function hasIgnoredIosProjectAsync(projectDir: string): Promise<boolean> {
const vcsClient = getVcsClient();
const vcsRootPath = path.normalize(await vcsClient.getRootPathAsync());
try {
const pbxProjectPath = IOSConfig.Paths.getPBXProjectPath(projectDir);
return await vcsClient.isFileIgnoredAsync(path.relative(vcsRootPath, pbxProjectPath));
} finally {
return false;
}
}
@@ -0,0 +1,200 @@
import { v4 as uuidv4 } from 'uuid';
import {
BranchMappingOperator,
alwaysTrue,
andStatement,
equalsOperator,
hashLtOperator,
} from '../../channel/branch-mapping';
import { isRollout } from '../utils';
const rolloutBranchMapping = {
version: 0,
data: [
{
branchId: uuidv4(),
branchMappingLogic: andStatement([
{
operand: '1.0.0',
clientKey: 'runtimeVersion',
branchMappingOperator: equalsOperator(),
},
{
operand: 10 / 100,
clientKey: 'rolloutToken',
branchMappingOperator: hashLtOperator(),
},
]),
},
{ branchId: uuidv4(), branchMappingLogic: alwaysTrue() },
],
};
const rolloutBranchMappingLegacy = {
version: 0,
data: [
{
branchId: uuidv4(),
branchMappingLogic: {
operand: 10 / 100,
clientKey: 'rolloutToken',
branchMappingOperator: hashLtOperator(),
},
},
{ branchId: uuidv4(), branchMappingLogic: alwaysTrue() },
],
};
const standardBranchMapping = {
version: 0,
data: [{ branchId: uuidv4(), branchMappingLogic: alwaysTrue() }],
};
describe(isRollout, () => {
it('detects a rollout made by the cli', () => {
expect(isRollout(rolloutBranchMappingLegacy)).toBe(true);
expect(isRollout(rolloutBranchMapping)).toBe(true);
});
it('detects custom mappings equivalent to rollouts made by the cli', () => {
const customMapping1 = {
version: 0,
data: [
{
branchId: uuidv4(),
branchMappingLogic: andStatement([
{
operand: 10 / 100,
clientKey: 'rolloutToken',
branchMappingOperator: hashLtOperator(),
},
{
operand: '1.0.0',
clientKey: 'runtimeVersion',
branchMappingOperator: equalsOperator(),
},
]),
},
{ branchId: uuidv4(), branchMappingLogic: alwaysTrue() },
],
};
expect(isRollout(customMapping1)).toBe(true);
});
it('correctly classifies branchMappings that arent rollouts', () => {
expect(isRollout(standardBranchMapping)).toBe(false);
const customMapping1 = {
version: 0,
data: [
{
branchId: uuidv4(),
branchMappingLogic: {
operand: 10 / 100,
clientKey: 'rolloutToken',
branchMappingOperator: 'hash_gt' as BranchMappingOperator,
},
},
{ branchId: uuidv4(), branchMappingLogic: alwaysTrue() },
],
};
expect(isRollout(customMapping1)).toBe(false);
const customMapping2 = {
version: 0,
data: [
{
branchId: uuidv4(),
branchMappingLogic: andStatement([
{
operand: '1.0.0',
clientKey: 'runtimeVersion',
branchMappingOperator: equalsOperator(),
},
{
operand: 10 / 100,
clientKey: 'FOOBAR',
branchMappingOperator: hashLtOperator(),
},
]),
},
{ branchId: uuidv4(), branchMappingLogic: alwaysTrue() },
],
};
expect(isRollout(customMapping2)).toBe(false);
const customMapping3 = {
version: 0,
data: [
{
branchId: uuidv4(),
branchMappingLogic: {
operand: 10 / 100,
clientKey: 'FOOBAR',
branchMappingOperator: hashLtOperator(),
},
},
{ branchId: uuidv4(), branchMappingLogic: alwaysTrue() },
],
};
expect(isRollout(customMapping3)).toBe(false);
const customMapping4 = {
version: 0,
data: [
{
branchId: uuidv4(),
branchMappingLogic: {
operand: 10 / 100,
clientKey: 'FOOBAR',
branchMappingOperator: hashLtOperator(),
},
},
],
};
expect(isRollout(customMapping4)).toBe(false);
const customMapping5 = {
version: 0,
data: [
{
branchId: uuidv4(),
branchMappingLogic: andStatement([
{
operand: '1.0.0',
clientKey: 'runtimeVersion',
branchMappingOperator: equalsOperator(),
},
{
operand: 10 / 100,
clientKey: 'rolloutToken',
branchMappingOperator: hashLtOperator(),
},
{
operand: '2.0.0',
clientKey: 'runtimeVersion',
branchMappingOperator: equalsOperator(),
},
]),
},
{ branchId: uuidv4(), branchMappingLogic: alwaysTrue() },
],
};
expect(isRollout(customMapping5)).toBe(false);
const customMapping6 = {
version: 0,
data: [
{ branchId: uuidv4(), branchMappingLogic: alwaysTrue() },
{
branchId: uuidv4(),
branchMappingLogic: {
operand: 10 / 100,
clientKey: 'rolloutToken',
branchMappingOperator: hashLtOperator(),
},
},
],
};
expect(isRollout(customMapping6)).toBe(false);
});
});
+116
View File
@@ -0,0 +1,116 @@
import {
BranchMapping,
BranchMappingNode,
getNodesFromStatement,
isAlwaysTrue,
isAndStatement,
isStatement,
} from '../channel/branch-mapping';
/**
* Detect if a branch mapping is a rollout.
*
* Types of rollout:
* 1. Legacy unconstrained rollout:
* Maps to a rollout branch via a rollout token
* Falls back to a default branch
*
* Example:
* {
version: 0,
data: [
{
branchId: uuidv4(),
branchMappingLogic: {
operand: 10 / 100,
clientKey: 'rolloutToken',
branchMappingOperator: hashLtOperator(),
},
},
{ branchId: uuidv4(), branchMappingLogic: alwaysTrue() },
],
}
*
* 2. RTV constrained rollout:
* Maps to a rollout branch via a rollout token, constrained by runtime version
* Falls back to a default branch
*
* Example:
* {
version: 0,
data: [
{
branchId: uuidv4(),
branchMappingLogic: andStatement([
{
operand: '1.0.0',
clientKey: 'runtimeVersion',
branchMappingOperator: equalsOperator(),
},
{
operand: 10 / 100,
clientKey: 'rolloutToken',
branchMappingOperator: hashLtOperator(),
},
]),
},
{ branchId: uuidv4(), branchMappingLogic: alwaysTrue() },
],
}
*/
export function isRollout(branchMapping: BranchMapping): boolean {
return isUnconstrainedRollout(branchMapping) || isRtvConstrainedRollout(branchMapping);
}
function isRtvConstrainedRollout(branchMapping: BranchMapping): boolean {
if (branchMapping.data.length !== 2) {
return false;
}
const hasRtvRolloutNode = isRtvConstrainedRolloutNode(branchMapping.data[0].branchMappingLogic);
const defaultsToAlwaysTrueNode = isAlwaysTrue(branchMapping.data[1].branchMappingLogic);
return hasRtvRolloutNode && defaultsToAlwaysTrueNode;
}
function isRtvConstrainedRolloutNode(node: BranchMappingNode): boolean {
if (!isStatement(node) || !isAndStatement(node)) {
return false;
}
const statementNodes = getNodesFromStatement(node);
if (statementNodes.length !== 2) {
return false;
}
const hasRuntimeVersionNode = statementNodes.some(isRuntimeVersionNode);
const hasRolloutNode = statementNodes.some(isRolloutNode);
return hasRuntimeVersionNode && hasRolloutNode;
}
function isUnconstrainedRollout(branchMapping: BranchMapping): boolean {
if (branchMapping.data.length !== 2) {
return false;
}
const hasRolloutNode = isRolloutNode(branchMapping.data[0].branchMappingLogic);
const defaultsToAlwaysTrueNode = isAlwaysTrue(branchMapping.data[1].branchMappingLogic);
return hasRolloutNode && defaultsToAlwaysTrueNode;
}
function isRuntimeVersionNode(node: BranchMappingNode): boolean {
if (typeof node === 'string') {
return false;
}
if (Array.isArray(node)) {
return false;
}
return node.clientKey === 'runtimeVersion' && node.branchMappingOperator === '==';
}
function isRolloutNode(node: BranchMappingNode): boolean {
if (typeof node === 'string') {
return false;
}
if (Array.isArray(node)) {
return false;
}
return node.clientKey === 'rolloutToken' && node.branchMappingOperator === 'hash_lt';
}
@@ -12,7 +12,7 @@ import {
AmbiguousApplicationIdError,
getApplicationIdAsync,
} from '../../project/android/applicationId';
import capitalize from '../../utils/expodash/capitalize';
import capitalizeFirstLetter from '../../utils/expodash/capitalize';
import { ArchiveSource } from '../ArchiveSource';
import { resolveArchiveSource } from '../commons';
import { SubmissionContext } from '../context';
@@ -33,9 +33,12 @@ export default class AndroidSubmitCommand {
const track = this.resolveTrack();
const releaseStatus = this.resolveReleaseStatus();
const archiveSource = this.resolveArchiveSource();
const rollout = this.resolveRollout();
const serviceAccountSource = await this.resolveServiceAccountSourceAsync();
const errored = [track, releaseStatus, archiveSource, serviceAccountSource].filter(r => !r.ok);
const errored = [track, releaseStatus, archiveSource, serviceAccountSource, rollout].filter(
r => !r.ok
);
if (errored.length > 0) {
const message = errored.map(err => err.reason?.message).join('\n');
Log.error(message);
@@ -46,6 +49,7 @@ export default class AndroidSubmitCommand {
projectId: this.ctx.projectId,
track: track.enforceValue(),
releaseStatus: releaseStatus.enforceValue(),
rollout: rollout.enforceValue(),
archiveSource: archiveSource.enforceValue(),
serviceAccountSource: serviceAccountSource.enforceValue(),
changesNotSentForReview: this.ctx.profile.changesNotSentForReview,
@@ -73,7 +77,7 @@ export default class AndroidSubmitCommand {
if (!track) {
return result(SubmissionAndroidTrack.Internal);
}
const capitalizedTrack = capitalize(track);
const capitalizedTrack = capitalizeFirstLetter(track);
if (capitalizedTrack in SubmissionAndroidTrack) {
return result(
SubmissionAndroidTrack[capitalizedTrack as keyof typeof SubmissionAndroidTrack]
@@ -94,7 +98,7 @@ export default class AndroidSubmitCommand {
if (!releaseStatus) {
return result(SubmissionAndroidReleaseStatus.Completed);
}
const capitalizedReleaseStatus = capitalize(releaseStatus);
const capitalizedReleaseStatus = capitalizeFirstLetter(releaseStatus);
if (capitalizedReleaseStatus in SubmissionAndroidReleaseStatus) {
return result(
SubmissionAndroidReleaseStatus[
@@ -112,6 +116,12 @@ export default class AndroidSubmitCommand {
}
}
private resolveRollout(): Result<number | undefined> {
const { rollout } = this.ctx.profile;
return result(rollout);
}
private resolveArchiveSource(): Result<ArchiveSource> {
try {
return result(resolveArchiveSource(this.ctx));
@@ -27,7 +27,7 @@ import {
export interface AndroidSubmissionOptions
extends Pick<
AndroidSubmissionConfigInput,
'track' | 'releaseStatus' | 'changesNotSentForReview'
'track' | 'releaseStatus' | 'changesNotSentForReview' | 'rollout'
> {
projectId: string;
archiveSource: ArchiveSource;
@@ -111,11 +111,12 @@ export default class AndroidSubmitter extends BaseSubmitter<
options: AndroidSubmissionOptions,
{ serviceAccountKeyResult }: ResolvedSourceOptions
): AndroidSubmissionConfigInput {
const { track, releaseStatus, changesNotSentForReview } = options;
const { track, releaseStatus, changesNotSentForReview, rollout } = options;
return {
track,
changesNotSentForReview,
releaseStatus,
rollout,
...serviceAccountKeyResult.result,
};
}
@@ -124,7 +125,7 @@ export default class AndroidSubmitter extends BaseSubmitter<
options: AndroidSubmissionOptions,
{ archive, serviceAccountKeyResult }: ResolvedSourceOptions
): SummaryData {
const { projectId, track, releaseStatus, changesNotSentForReview } = options;
const { projectId, track, releaseStatus, changesNotSentForReview, rollout } = options;
// structuring order affects table rows order
return {
@@ -133,6 +134,7 @@ export default class AndroidSubmitter extends BaseSubmitter<
changesNotSentForReview: changesNotSentForReview ?? undefined,
releaseStatus: releaseStatus ?? undefined,
formattedServiceAccount: formatServiceAccountSummary(serviceAccountKeyResult),
rollout: rollout ?? undefined,
...formatArchiveSourceSummary(archive),
};
}
@@ -143,6 +145,7 @@ type SummaryData = {
formattedServiceAccount: string;
projectId: string;
releaseStatus?: SubmissionAndroidReleaseStatus;
rollout?: number;
track: SubmissionAndroidTrack;
} & ArchiveSourceSummaryFields;
@@ -154,6 +157,7 @@ const SummaryHumanReadableKeys: Record<keyof SummaryData, string> = {
formattedServiceAccount: 'Google Service Account Key',
projectId: 'Project ID',
releaseStatus: 'Release status',
rollout: 'Rollout',
track: 'Release track',
};
@@ -145,6 +145,46 @@ describe(AndroidSubmitCommand, () => {
});
});
it('sends a request to EAS Submit when using inProgress status', async () => {
const projectId = uuidv4();
const graphqlClient = {} as any as ExpoGraphqlClient;
const analytics = instance(mock<Analytics>());
const ctx = await createSubmissionContextAsync({
platform: Platform.ANDROID,
projectDir: testProject.projectRoot,
archiveFlags: {
url: 'http://expo.dev/fake.apk',
},
profile: {
serviceAccountKeyPath: '/google-service-account.json',
track: AndroidReleaseTrack.internal,
releaseStatus: AndroidReleaseStatus.inProgress,
changesNotSentForReview: false,
},
nonInteractive: false,
actor: mockJester,
graphqlClient,
analytics,
exp: testProject.appJSON.expo,
projectId,
});
const command = new AndroidSubmitCommand(ctx);
await command.runAsync();
expect(SubmissionMutation.createAndroidSubmissionAsync).toHaveBeenCalledWith(graphqlClient, {
appId: projectId,
archiveSource: { type: SubmissionArchiveSourceType.Url, url: 'http://expo.dev/fake.apk' },
config: {
googleServiceAccountKeyJson: fakeFiles['/google-service-account.json'],
releaseStatus: SubmissionAndroidReleaseStatus.InProgress,
track: SubmissionAndroidTrack.Internal,
changesNotSentForReview: false,
},
});
});
it('assigns the build ID to submission', async () => {
const projectId = uuidv4();
const graphqlClient = {} as any as ExpoGraphqlClient;
+48 -15
View File
@@ -1,3 +1,4 @@
import assert from 'assert';
import openBrowserAsync from 'better-opn';
import http from 'http';
import { Socket } from 'node:net';
@@ -5,22 +6,48 @@ import querystring from 'querystring';
import Log from '../log';
export async function getSessionUsingBrowserAuthFlowAsync(options: {
const successBody = `
<!DOCTYPE html>
<html lang="en">
<head>
<title>Expo SSO Login</title>
<meta charset="utf-8">
<style type="text/css">
html {
margin: 0;
padding: 0
}
body {
background-color: #fff;
font-family: Tahoma,Verdana;
font-size: 16px;
color: #000;
max-width: 100%;
box-sizing: border-box;
padding: .5rem;
margin: 1em;
overflow-wrap: break-word
}
</style>
</head>
<body>
SSO login complete. You may now close this tab and return to the command prompt.
</body>
</html>`;
export async function getSessionUsingBrowserAuthFlowAsync({
expoWebsiteUrl,
}: {
expoWebsiteUrl: string;
serverPort: number;
}): Promise<string> {
const { expoWebsiteUrl, serverPort } = options;
if (!expoWebsiteUrl || !serverPort) {
throw new Error('Expo website URL and local server port are required.');
}
const scheme = 'http';
const hostname = 'localhost';
const path = '/auth/callback';
const redirectUri = `${scheme}://${hostname}:${serverPort}${path}`;
const buildExpoSsoLoginUrl = (): string => {
const buildExpoSsoLoginUrl = (port: number): string => {
const data = {
app_redirect_uri: redirectUri,
app_redirect_uri: `${scheme}://${hostname}:${port}${path}`,
};
const params = querystring.stringify(data);
return `${expoWebsiteUrl}/sso-login?${params}`;
@@ -44,8 +71,8 @@ export async function getSessionUsingBrowserAuthFlowAsync(options: {
throw new Error('Request missing session_secret search parameter.');
}
resolve(sessionSecret);
response.writeHead(200, { 'Content-Type': 'text/plain' });
response.write(`Website login has completed. You can now close this tab.`);
response.writeHead(200, { 'Content-Type': 'text/html' });
response.write(successBody);
response.end();
} catch (error) {
reject(error);
@@ -59,8 +86,17 @@ export async function getSessionUsingBrowserAuthFlowAsync(options: {
}
);
server.listen(serverPort, hostname, () => {
server.listen(0, hostname, () => {
Log.log('Waiting for browser login...');
const address = server.address();
assert(
address !== null && typeof address === 'object',
'Server address and port should be set after listening has begun'
);
const port = address.port;
const authorizeUrl = buildExpoSsoLoginUrl(port);
openBrowserAsync(authorizeUrl);
});
server.on('connection', connection => {
@@ -70,9 +106,6 @@ export async function getSessionUsingBrowserAuthFlowAsync(options: {
connections.delete(connection);
});
});
const authorizeUrl = buildExpoSsoLoginUrl();
openBrowserAsync(authorizeUrl);
});
};
@@ -1,4 +1,4 @@
import { getExpoWebsiteBaseUrl, getSsoLocalServerPortAsync } from '../api';
import { getExpoWebsiteBaseUrl } from '../api';
import { getSessionUsingBrowserAuthFlowAsync } from './expoSsoLauncher';
import { fetchUserAsync } from './fetchUser';
@@ -7,11 +7,9 @@ export async function fetchSessionSecretAndSsoUserAsync(): Promise<{
id: string;
username: string;
}> {
const config = {
const sessionSecret = await getSessionUsingBrowserAuthFlowAsync({
expoWebsiteUrl: getExpoWebsiteBaseUrl(),
serverPort: await getSsoLocalServerPortAsync(),
};
const sessionSecret = await getSessionUsingBrowserAuthFlowAsync(config);
});
const userData = await fetchUserAsync({ sessionSecret });
@@ -1,10 +1,13 @@
import capitalize from '../capitalize';
import capitalizeFirstLetter from '../capitalize';
describe(capitalize, () => {
describe(capitalizeFirstLetter, () => {
it('capitalizes the string', () => {
expect(capitalize('dominik')).toBe('Dominik');
expect(capitalizeFirstLetter('dominik')).toBe('Dominik');
});
it('works with an empty string', () => {
expect(capitalize('')).toBe('');
expect(capitalizeFirstLetter('')).toBe('');
});
it('does not change the case of other letters', () => {
expect(capitalizeFirstLetter('inProgress')).toBe('InProgress');
});
});
@@ -1,3 +1,3 @@
export default function capitalize(s: string): string {
return s ? s.charAt(0).toUpperCase() + s.slice(1).toLowerCase() : '';
export default function capitalizeFirstLetter(s: string): string {
return s ? s.charAt(0).toUpperCase() + s.slice(1) : '';
}
-11
View File
@@ -1,11 +0,0 @@
import freeportAsync from 'freeport-async';
/** Get a free port or throw an error. */
export async function getFreePortAsync(rangeStart: number): Promise<number> {
const port = await freeportAsync(rangeStart, { hostnames: [null, 'localhost'] });
if (!port) {
throw new Error('No available port found');
}
return port;
}
+8
View File
@@ -0,0 +1,8 @@
{
"extends": "./tsconfig.build",
"compilerOptions": {
"noUnusedLocals": true,
"noUnusedParameters": true
},
"exclude": ["**/__mocks__/*", "**/__tests__/*"]
}
+2 -2
View File
@@ -7,8 +7,8 @@
"noFallthroughCasesInSwitch": true,
"noImplicitOverride": true,
"noImplicitReturns": true,
"noUnusedLocals": true,
"noUnusedParameters": true,
"noUnusedLocals": false,
"noUnusedParameters": false,
"strict": true,
"target": "ES2019",
"outDir": "build",
+4 -3
View File
@@ -1,7 +1,7 @@
{
"name": "@expo/eas-json",
"description": "A library for interacting with eas.json",
"version": "3.15.1",
"version": "3.17.0",
"author": "Expo <[email protected]>",
"bugs": "https://github.com/expo/eas-cli/issues",
"dependencies": {
@@ -34,10 +34,11 @@
"repository": "expo/eas-cli",
"scripts": {
"build": "tsc --project tsconfig.build.json",
"build-ci": "tsc --project tsconfig.build-ci.json",
"watch": "yarn build --watch --preserveWatchOutput",
"typecheck": "tsc",
"typecheck": "tsc --project tsconfig.build-ci.json",
"prepack": "yarn rebuild",
"rebuild": "rimraf build && yarn build",
"rebuild": "rimraf build && yarn build-ci",
"test": "jest",
"clean": "rimraf build node_modules yarn-error.log"
},
+6 -1
View File
@@ -363,7 +363,7 @@
"default": "default",
"anyOf": [
{
"enum": ["default", "medium", "large", "intel-medium", "m-medium"]
"enum": ["default", "medium", "large", "m-medium"]
},
{
"type": "string"
@@ -464,6 +464,11 @@
"The release will have no further changes. Its APKs are being served to all users, unless they are eligible to APKs of a more recent release."
]
},
"rollout": {
"type": "number",
"description": "The initial fraction of users who are eligible to receive the release. Should be a value from 0 (no users) to 1 (all users). Works only with 'inProgress' release status. Learn more: https://developers.google.com/android-publisher/api-ref/rest/v3/edits.tracks",
"markdownDescription": "The initial fraction of users who are eligible to receive the release. Should be a value from 0 (no users) to 1 (all users). Works only with `inProgress` release status. [Learn more](https://developers.google.com/android-publisher/api-ref/rest/v3/edits.tracks)"
},
"changesNotSentForReview": {
"type": "boolean",
"description": "Indicates that the changes sent with this submission will not be reviewed until they are explicitly sent for review from the Google Play Console UI. Defaults to false.",
@@ -3,6 +3,8 @@ import fs from 'fs-extra';
import { vol } from 'memfs';
import { EasJsonAccessor } from '../accessor';
import { InvalidEasJsonError } from '../errors';
import { AndroidReleaseStatus } from '../submit/types';
import { EasJsonUtils } from '../utils';
jest.mock('fs');
@@ -237,3 +239,157 @@ test('get profile names', async () => {
const allProfileNames = await EasJsonUtils.getSubmitProfileNamesAsync(accessor);
expect(allProfileNames.sort()).toEqual(['production', 'blah'].sort());
});
test.each([
AndroidReleaseStatus.completed,
AndroidReleaseStatus.draft,
AndroidReleaseStatus.halted,
])('android config with releaseStatus %s is valid when rollout is not set', async releaseStatus => {
await fs.writeJson('/project/eas.json', {
submit: {
production: {
android: {
serviceAccountKeyPath: './path.json',
track: 'beta',
releaseStatus,
},
},
},
});
const accessor = EasJsonAccessor.fromProjectPath('/project');
const androidProfile = await EasJsonUtils.getSubmitProfileAsync(
accessor,
Platform.ANDROID,
'production'
);
expect(androidProfile).toEqual({
serviceAccountKeyPath: './path.json',
track: 'beta',
releaseStatus,
changesNotSentForReview: false,
});
});
test.each([
AndroidReleaseStatus.completed,
AndroidReleaseStatus.draft,
AndroidReleaseStatus.halted,
])('android config with releaseStatus %s is invalid when rollout is set', async releaseStatus => {
await fs.writeJson('/project/eas.json', {
submit: {
production: {
android: {
serviceAccountKeyPath: './path.json',
track: 'beta',
releaseStatus,
rollout: 0.5,
},
},
},
});
const accessor = EasJsonAccessor.fromProjectPath('/project');
const promise = EasJsonUtils.getSubmitProfileAsync(accessor, Platform.ANDROID, 'production');
await expect(promise).rejects.toThrowError(InvalidEasJsonError);
});
test(`android config with releaseStatus ${AndroidReleaseStatus.inProgress} is invalid when rollout is not set`, async () => {
await fs.writeJson('/project/eas.json', {
submit: {
production: {
android: {
serviceAccountKeyPath: './path.json',
track: 'beta',
releaseStatus: AndroidReleaseStatus.inProgress,
},
},
},
});
const accessor = EasJsonAccessor.fromProjectPath('/project');
const promise = EasJsonUtils.getSubmitProfileAsync(accessor, Platform.ANDROID, 'production');
await expect(promise).rejects.toThrowError(InvalidEasJsonError);
await expect(promise).rejects.toThrowError(/"submit\.production\.android\.rollout" is required/);
});
test(`android config with releaseStatus ${AndroidReleaseStatus.inProgress} is valid when rollout is set`, async () => {
await fs.writeJson('/project/eas.json', {
submit: {
production: {
android: {
serviceAccountKeyPath: './path.json',
track: 'beta',
releaseStatus: AndroidReleaseStatus.inProgress,
rollout: 0.5,
},
},
},
});
const accessor = EasJsonAccessor.fromProjectPath('/project');
const androidProfile = await EasJsonUtils.getSubmitProfileAsync(
accessor,
Platform.ANDROID,
'production'
);
expect(androidProfile).toEqual({
serviceAccountKeyPath: './path.json',
track: 'beta',
releaseStatus: AndroidReleaseStatus.inProgress,
changesNotSentForReview: false,
rollout: 0.5,
});
});
test.each([0, 1, 0.2, 0.75, 0.22])('rollout value %s is valid', async rollout => {
await fs.writeJson('/project/eas.json', {
submit: {
production: {
android: {
serviceAccountKeyPath: './path.json',
track: 'beta',
releaseStatus: AndroidReleaseStatus.inProgress,
rollout,
},
},
},
});
const accessor = EasJsonAccessor.fromProjectPath('/project');
const androidProfile = await EasJsonUtils.getSubmitProfileAsync(
accessor,
Platform.ANDROID,
'production'
);
expect(androidProfile).toEqual({
serviceAccountKeyPath: './path.json',
track: 'beta',
releaseStatus: AndroidReleaseStatus.inProgress,
changesNotSentForReview: false,
rollout,
});
});
test.each([-5, 12, 1.2, 1.01, 99])('rollout value %s is invalid', async rollout => {
await fs.writeJson('/project/eas.json', {
submit: {
production: {
android: {
serviceAccountKeyPath: './path.json',
track: 'beta',
releaseStatus: AndroidReleaseStatus.inProgress,
rollout,
},
},
},
});
const accessor = EasJsonAccessor.fromProjectPath('/project');
const promise = EasJsonUtils.getSubmitProfileAsync(accessor, Platform.ANDROID, 'production');
await expect(promise).rejects.toThrowError(InvalidEasJsonError);
});
+5
View File
@@ -12,6 +12,11 @@ export const AndroidSubmitProfileSchema = Joi.object({
.default(AndroidReleaseStatus.completed),
changesNotSentForReview: Joi.boolean().default(false),
applicationId: Joi.string(),
rollout: Joi.number().min(0).max(1).when('releaseStatus', {
is: AndroidReleaseStatus.inProgress,
then: Joi.required(),
otherwise: Joi.forbidden(),
}),
});
export const IosSubmitProfileSchema = Joi.object({
+1
View File
@@ -20,6 +20,7 @@ export interface AndroidSubmitProfile {
releaseStatus: AndroidReleaseStatus;
changesNotSentForReview: boolean;
applicationId?: string;
rollout?: number;
}
export const AndroidSubmitProfileFieldsToEvaluate: (keyof AndroidSubmitProfile)[] = [
+8
View File
@@ -0,0 +1,8 @@
{
"extends": "./tsconfig.build",
"compilerOptions": {
"noUnusedLocals": true,
"noUnusedParameters": true
},
"exclude": ["**/__mocks__/*", "**/__tests__/*"]
}
+2 -2
View File
@@ -7,8 +7,8 @@
"noFallthroughCasesInSwitch": true,
"noImplicitOverride": true,
"noImplicitReturns": true,
"noUnusedLocals": true,
"noUnusedParameters": true,
"noUnusedLocals": false,
"noUnusedParameters": false,
"strict": true,
"target": "ES2019",
"outDir": "build",
-8
View File
@@ -1,8 +0,0 @@
declare module 'freeport-async' {
interface FreePortOptions {
hostnames?: (string | null)[];
}
function freePortAsync(rangeStart: number, options?: FreePortOptions): Promise<number>;
export = freePortAsync;
}
Generated
+21 -25
View File
@@ -2,6 +2,11 @@
# yarn lockfile v1
"@0no-co/graphql.web@^1.0.1":
version "1.0.4"
resolved "https://registry.yarnpkg.com/@0no-co/graphql.web/-/graphql.web-1.0.4.tgz#9606eb651955499525d068ce0ad8bea596286ce2"
integrity sha512-W3ezhHGfO0MS1PtGloaTpg0PbaT8aZSmmaerL7idtU5F7oCI+uu25k+MsMS31BVFlp4aMkHSrNRxiD72IlK8TA==
"@ampproject/remapping@^2.1.0":
version "2.2.0"
resolved "https://registry.yarnpkg.com/@ampproject/remapping/-/remapping-2.2.0.tgz#56c133824780de3174aed5ab6834f3026790154d"
@@ -4537,20 +4542,21 @@
"@typescript-eslint/types" "5.33.0"
eslint-visitor-keys "^3.3.0"
"@urql/core@3.1.1", "@urql/core@>=3.0.0":
version "3.1.1"
resolved "https://registry.yarnpkg.com/@urql/core/-/core-3.1.1.tgz#a49cd572360d01f2469a786b294fba2269a65e53"
integrity sha512-Mnxtq4I4QeFJsgs7Iytw+HyhiGxISR6qtyk66c9tipozLZ6QVxrCiUPF2HY4BxNIabaxcp+rivadvm8NAnXj4Q==
"@urql/core@4.0.11", "@urql/core@>=4.0.0":
version "4.0.11"
resolved "https://registry.yarnpkg.com/@urql/core/-/core-4.0.11.tgz#b4e8bf3a3ff1a2519bb3aec38c7be99d2523308d"
integrity sha512-FFdY97vF5xnUrElcGw9erOLvtu+KGMLfwrLNDfv4IPgdp2IBsiGe+Kb7Aypfd3kH//BETewVSLm3+y2sSzjX6A==
dependencies:
wonka "^6.1.2"
"@0no-co/graphql.web" "^1.0.1"
wonka "^6.3.2"
"@urql/exchange-retry@1.0.0":
version "1.0.0"
resolved "https://registry.yarnpkg.com/@urql/exchange-retry/-/exchange-retry-1.0.0.tgz#25a48ef0c2f6854f5617e2ca4ea25ae240f1fcbc"
integrity sha512-UGyyGAMXzop9C/fIoe7Ij63DkPSy1uMw2jipB5dnB8R3kl80za7LYzVnA1HvBEt2ZPWfMuwez/VGLOQ7XX4bTA==
"@urql/exchange-retry@1.2.0":
version "1.2.0"
resolved "https://registry.yarnpkg.com/@urql/exchange-retry/-/exchange-retry-1.2.0.tgz#23d3ec711754e3c67a843e0106f2cabddff2e5ff"
integrity sha512-1O/biKiVhhn0EtvDF4UOvz325K4RrLupfL8rHcmqD2TBLv4qVDWQuzx4JGa1FfqjjRb+C9TNZ6w19f32Mq85Ug==
dependencies:
"@urql/core" ">=3.0.0"
wonka "^6.0.0"
"@urql/core" ">=4.0.0"
wonka "^6.3.2"
"@whatwg-node/[email protected]", "@whatwg-node/fetch@^0.5.0":
version "0.5.4"
@@ -7441,11 +7447,6 @@ [email protected]:
resolved "https://registry.yarnpkg.com/forwarded/-/forwarded-0.2.0.tgz#2269936428aad4c15c7ebe9779a84bf0b2a81811"
integrity sha512-buRG0fpBtRHSTCOASe6hD258tEubFoRLb4ZNA6NxMVHNw2gOcwHo9wyablzMzOA5z9xA9L1KNjk/Nt6MT9aYow==
[email protected]:
version "2.0.0"
resolved "https://registry.yarnpkg.com/freeport-async/-/freeport-async-2.0.0.tgz#6adf2ec0c629d11abff92836acd04b399135bab4"
integrity sha512-K7od3Uw45AJg00XUmy15+Hae2hOcgKcmN3/EF6Y7i01O0gaqiRx8sUSpsb9+BRNL8RPBrhzPsVfy8q9ADlJuWQ==
[email protected]:
version "0.5.2"
resolved "https://registry.yarnpkg.com/fresh/-/fresh-0.5.2.tgz#3d8cadd90d976569fa835ab1f8e4b23a105605a7"
@@ -13621,15 +13622,10 @@ widest-line@^3.1.0:
dependencies:
string-width "^4.0.0"
wonka@^6.0.0:
version "6.1.0"
resolved "https://registry.yarnpkg.com/wonka/-/wonka-6.1.0.tgz#65297ebf7031ae46d4b0c56da93950fb3ae5baaa"
integrity sha512-VgiMCz7BXOiDbgpVhf5iNhK7hurteY5Jv0fDJewUkY0s4fbxQD2iKqfGxNXNTwp2v3bgT8QVu2l5H7YdkZ5WIA==
wonka@^6.1.2:
version "6.1.2"
resolved "https://registry.yarnpkg.com/wonka/-/wonka-6.1.2.tgz#2c66fa5b26a12f002a03619b988258313d0b5352"
integrity sha512-zNrXPMccg/7OEp9tSfFkMgTvhhowqasiSHdJ3eCZolXxVTV/aT6HUTofoZk9gwRbGoFey/Nss3JaZKUMKMbofg==
wonka@^6.3.2:
version "6.3.2"
resolved "https://registry.yarnpkg.com/wonka/-/wonka-6.3.2.tgz#6f32992b332251d7b696b038990f4dc284b3b33d"
integrity sha512-2xXbQ1LnwNS7egVm1HPhW2FyKrekolzhpM3mCwXdQr55gO+tAiY76rhb32OL9kKsW8taj++iP7C6hxlVzbnvrw==
word-wrap@^1.2.3:
version "1.2.3"