Skip to content

Commands

rn-shipyard [--json] [--non-interactive] [-V, --version] [-h, --help] <command>
FlagDescription
--jsonMachine-readable output, see JSON output and exit codes
--non-interactiveNever prompt. Fail with a clear error instead
-V, --versionPrint the version
-h, --helpHelp for the program or a command

Global flags work before or after the command name.

Terminal window
rn-shipyard doctor [-p, --platform <ios|android|all>]

Checks that this Mac can build and submit, and prints a fix for each problem.

FlagDefaultDescription
-p, --platform <platform>allios, android or all

The output is grouped: System, iOS, Android, Project, Signing & submit. Groups where everything passes collapse to one line. Each check is ✓, ! or ✗, with a copy-paste Fix: line under every problem. A readiness summary says which of iOS build, Android build, iOS submit and Android submit are ready, and a “Next step” line names what to do first. A platform that is not in .shipyard/config.json is “not set up” (next step: rn-shipyard init --platform <p>), and a submit is ready only when a successful build in history still has its .ipa/.aab on disk (otherwise: no .ipa yet: run rn-shipyard build --platform ios). In --json, readiness.<action> then carries state (not-set-up or no-artifact) and note. A warning (never a failure, nothing is deleted) appears when EAS’s plaintext credentials.json / credentials/ are still on disk after a successful build, with the exact rm command and whether they are git-ignored or tracked. A separate check, xcode-sdk, uses the minimum Xcode your project’s Expo SDK needs (from Expo’s support table: 26.4 for SDK 56 to 58, 26.2 for SDK 55, 16.1 for SDK 54, 16.0 for SDK 53), read from the installed expo package or the expo range in package.json; the check title names it, for example Xcode >= 26.4 (Expo SDK 58). A too-old Xcode for a listed SDK is a failure (Xcode 26.3 is too old for Expo SDK 58, which needs 26.4 or newer) with the xcode-select -s fix for machines with several Xcodes. It blocks only build (init and submit do not run it; doctor shows it). An SDK newer than the table is assumed to need at least 26.4 and an older one falls back to Xcode 16.0, both as a warning only; a project without Expo, or without Xcode, skips it (the plain Xcode >= 15 check still covers that). For Android it also checks that /bin/sh keeps environment variables with dots in their name. Unlike the pre-flight that build, submit and init run, doctor also checks that the Match certificates repo is reachable (a git ls-remote, which needs the network) and that App Store Connect credentials are present. The EAS names (EXPO_APPLE_ID and the others) count like their Fastlane equivalents. See Requirements.

With --json it prints success, checks, readiness, summary and nextStep, plus error when something failed.

Exit 0 if nothing fails (warnings alone are fine), 1 on any ✗, 2 when only project config is missing.

Terminal window
rn-shipyard init [-p, --platform <ios|android|all>]
[--android-keystore <path>]
[--android-credentials <path>]
[--android-last-version-code <n>]
[--from-eas [path]]
[--save-match-password]

One-time setup for the project.

FlagDefaultDescription
-p, --platform <platform>allios, android or all
--android-keystore <path>Use an existing keystore instead of generating one
--android-credentials <path>JSON file with keystorePassword, keyAlias, keyPassword. Keep it outside the repo
--android-last-version-code <n>Seed the versionCode counter, for example with EAS’s remote counter
--from-eas [path]Import the signing credentials eas credentials downloaded (credentials.json, default ./credentials.json; a folder with one also works). Cannot be combined with --android-keystore or --android-credentials
--save-match-passwordiOS: save MATCH_PASSWORD from the environment in the macOS keychain item fastlane match reads. Works with --non-interactive; in a terminal it answers the keychain offer with yes. Unset or empty MATCH_PASSWORD: MATCH_PASSWORD_MISSING (exit 1)

Interactive by default when stdin and stdout are a terminal. With --non-interactive, with --json, when CI is set (and not 0 or false), or when stdin or stdout is not a TTY, init never prompts: values come from environment variables and your Expo config, and a missing value exits 2. Piped answers are not supported. Password prompts do not echo and never show a value taken from the environment (they show [from env]; Enter accepts it).

Before anything else, init runs the requirements pre-flight for the selected platforms (see build). It leaves out the checks for what init creates: .shipyard/config.json, eas.json and the whole Signing & submit group. A blocking problem stops init with REQUIREMENTS_NOT_MET (exit 1) or MISSING_CONFIG_PROJECT (exit 2).

What it does:

  • Merging: init --platform ios (or android) merges into an existing .shipyard/config.json. The other platform’s block, version-code.json and history.json are left as they are, fastlane/Fastfile, Appfile and Matchfile are regenerated for every configured platform, and re-running for the same platform replaces only that block (its prompts default to the existing values; an Android re-run keeps the keystore, alias and credentials file already configured). An unreadable config stops with INVALID_CONFIG instead of being overwritten.
  • iOS: asks for bundle identifier, Apple Team ID and the Match Git URL, with defaults from app.json, eas.json, APPLE_TEAM_ID, MATCH_GIT_URL and the existing config. The Match password is taken from MATCH_PASSWORD, else from the macOS keychain item fastlane match reads itself (an internet password with server match_<git url>; checked with security find-internet-password by exit code only, the password is never read). In a terminal, when neither exists, init offers to save it: it runs security add-internet-password -a "" -s match_<git url> -U -w on your terminal, so security asks for the password itself and it never appears in a command line. --save-match-password does the same without a terminal and without asking: it takes the value from MATCH_PASSWORD and sends add-internet-password -a "" -s match_<git url> -U -w "<password>" to security -i on stdin, so the password is never in a command line (it saves only after Match or the import succeeded, so a mistyped password cannot replace a good item; otherwise --json has setup.ios.matchPasswordKeychain: "not-saved" with matchPasswordKeychainReason, and "saved" on success; passwords over 1024 bytes are refused; a failed save is KEYCHAIN_SAVE_FAILED, exit 1). Then it runs Match through the internal Fastfile lane shipyard_match_setup, after fastlane/ is written. The lane signs in with your App Store Connect API key when one is configured (it calls app_store_connect_api_key with the key file read in place, then match), otherwise Match asks for an Apple ID. --json has setup.ios.matchAuth (api-key or apple-id). Non-interactive with neither a key nor FASTLANE_USER (or appleId in eas.json), init does not start fastlane: setup.ios.status is "failed" with errorCode: "MATCH_AUTH_MISSING" and a nextStep. If Match fails with a key the key check found forbidden, the nextStep adds that the role may be too low (App Manager or Admin) and names FASTLANE_USER. Match runs in a terminal on your own terminal (so Git, SSH, Apple ID and 2FA prompts work, and its output is not redacted), otherwise piped, detached from the terminal and redacted. With neither source it skips Match; the text summary then says “Match signing NOT set up” and --json has setup.ios.status: "skipped" with a nextStep ("configured" and "imported" for --from-eas also exit 0). If Match ends "failed" (a Match error, or MATCH_AUTH_MISSING), init still writes the config and Fastfile and prints every platform’s status, but exits 1; --json then has success: false and error: { code, message, fix } (the errorCode of the platform, else MATCH_SETUP_FAILED; message is setup.ios.reason, fix is setup.ios.nextStep) together with the full setup. With two failed platforms error describes the first. A platform you declined in a terminal is skipped and exits 0. CI uses the environment variable; locally the keychain is enough. The EXPO_* credential names are accepted, see Environment variables.
  • App Store Connect key check (iOS): if an API key is configured (APP_STORE_CONNECT_API_KEY_KEY_ID, _ISSUER_ID, _KEY or _KEY_FILEPATH, their EXPO_ASC_* aliases, or ascApiKey* in eas.json), init signs a short-lived ES256 token with the .p8 (nothing is logged) and calls GET https://api.appstoreconnect.apple.com/v1/apps?filter[bundleId]=<bundle id>&limit=1 (15 s timeout) before Match starts. 401 stops with ASC_KEY_INVALID; a role that is too low (403, the key needs App Manager or Admin for submit), an unknown app record or a network error only warns, because building does not need the key. --json reports setup.ios.ascKey (ok, forbidden, app-not-found, unreachable, skipped). This is the only network call init makes itself; doctor and the build pre-flight still make none.
  • Android: generates .shipyard/android/release.keystore with keytool, or adopts the keystore you pass.
  • Writes .shipyard/config.json, .shipyard/.gitignore, fastlane/Fastfile, Appfile (and Matchfile for iOS), and appends keystore and artifact patterns to your project .gitignore.

--from-eas: reads the EAS credentials.json and imports it. Android: the keystore is verified with keytool (alias and key password too), copied to ~/.config/rn-shipyard/<slug>/ (folder 700, files 600), its SHA-256 fingerprint is printed, and .shipyard/config.json is configured like --android-keystore plus --android-credentials. iOS: the distribution certificate is converted with openssl in a private temp folder, then fastlane match import (internal lane shipyard_match_import) encrypts it with MATCH_PASSWORD and pushes it with every target’s provisioning profile to the Match repo; it needs MATCH_GIT_URL, APPLE_TEAM_ID, MATCH_PASSWORD and an Apple login (a terminal, or an App Store Connect API key with --non-interactive). A platform missing from the file is skipped with a warning. If the default ./credentials.json is missing and you are in a terminal, init prints the exact eas-cli menu path and every answer (including “Do you want to log in to your Apple account?”: answer n, the download only reads Expo’s servers) and offers to run npx eas-cli credentials -p <platform> for you, then continues; with --non-interactive it stops with EAS_CREDENTIALS_NOT_FOUND (exit 2) and the menu path in fix, because eas-cli has no non-interactive download. --json always has setup (per-platform status, preserved platforms kept from the existing config) and nextSteps; with --from-eas it adds imported (paths as ~/..., fingerprints, never a password) and plaintextFiles. The EAS files are never deleted: the delete command is printed once a build works. See Migrating from EAS.

Flag errors: an Android flag with --platform ios, --android-credentials without a keystore, or a bad --android-last-version-code give INVALID_FLAGS.

Terminal window
rn-shipyard build [-p, --platform <ios|android|all>] [--profile <name>] [--submit]
[--skip-version-check] [--version-code <n>] [--build-number <n>] [--skip-checks]
FlagDefaultDescription
-p, --platform <platform>allios, android or all
--profile <profile>productionBuild profile from eas.json
--submitoffSubmit after a successful build, with the same --profile. Only if no platform failed
--skip-version-checkoffSkip the warning about an unchanged iOS version
--version-code <n>Android versionCode. Must be greater than the last used one. Rejected when android/ is tracked in git
--build-number <n>iOS build number (CFBundleVersion). Must be greater than the last used one, and than the latest TestFlight build when an API key is available
--skip-checksoffSkip the requirements pre-flight (the doctor checks that run first). It makes no network calls

Per platform: decide whether expo prebuild --clean may run, run it, build with Fastlane, write the artifact to output/, record history. iOS and Android run one after the other, independently. The iOS workspace is the single ios/*.xcworkspace found after prebuild, and its name is the scheme.

ios/ or android/What happens
tracked in gitprebuild is skipped, the committed project is built as is
missinggenerated with expo prebuild
present and git-ignoredregenerated with expo prebuild --clean
present, untracked, not ignoredrefused with NATIVE_DIR_UNTRACKED
present, project not under gitrefused with NATIVE_DIR_NOT_IN_GIT

After prebuild, package.json and the lockfiles are restored if prebuild rewrote them.

The iOS lane then runs Match (read-only), reads the latest TestFlight build number if an App Store Connect API key is set, applies manual signing and the build number to the generated project, and archives with gym. See iOS signing and Version numbers. A failed build reports the real error line (xcodebuild or Gradle error:, else fastlane’s [!] line, else the last 15 lines); the Gemfile tip and update notices are ignored. On iOS, gym’s full log is written to .shipyard/logs/ (gitignored); if the output has only an error: ...: header, the reason is taken from that log, and the error ends with Full log: <path>. The same text goes to --json (platforms.<platform>.error) and to history.

With --json the result is { success, platforms, prebuild, warnings }. prebuild.<platform>.action is generated, skipped_tracked or refused.

Exit 0 all platforms succeeded, 1 any failed, 2 not initialized.

Once .shipyard/config.json is found, build runs the doctor checks for the enabled platforms before any prompt or long step (with --submit, the submit checks too). A ✗ stops the run with REQUIREMENTS_NOT_MET (exit 1), or MISSING_CONFIG_PROJECT (exit 2) when only project config is missing. It prints each failed check with its fix, and with --json the same document as doctor --json with success: false. Warnings are printed and never block. The pre-flight makes no network calls, so it leaves out the Match repo check (the iOS build clones that repo right away and fails fast) and the App Store Connect credentials check (submit has its own). --skip-checks bypasses it. Without MATCH_PASSWORD, an interactive build only warns; with --non-interactive (or CI, or no TTY) it is a blocking problem.

app.config.* is evaluated with npx expo config --json, with the env of the selected profile applied. If version is not set, rn-shipyard warns and uses 1.0.0, as Expo does. See Dynamic config.

Everything that may prompt runs first, on your real terminal; after that the build runs piped and redacted, see CI and scripting.

  • build --submit with an Apple ID (no App Store Connect API key): the question Log in to your Apple account now? (Y/n) is asked right after the pre-flight, before the build starts. Answer yes and Fastlane asks for the password and 2FA code. Ctrl-C at the question aborts the run with exit 130 and builds and uploads nothing. Closed input (Ctrl-D) counts as no.
  • iOS: before the build lane, rn-shipyard clones the Match repo itself (a bare clone into a private temp dir, removed afterwards). In a terminal, git and ssh may prompt on your terminal (ssh passphrase, https credentials, credential helpers). With --non-interactive the clone cannot prompt: ssh runs in BatchMode, and a failure stops that platform with MATCH_REPO_AUTH_FAILED. The clone is skipped when MATCH_GIT_BASIC_AUTHORIZATION, MATCH_GIT_BEARER_AUTHORIZATION or MATCH_GIT_PRIVATE_KEY is set, since Fastlane authenticates with those without prompting.
Terminal window
rn-shipyard submit [-p, --platform <ios|android|all>] [--profile <name>] [--dry-run] [--skip-checks]
FlagDefaultDescription
-p, --platform <platform>allios, android or all
--profile <profile>productionSubmit profile from eas.json
--dry-runoffCheck everything and print the Fastlane command without uploading. Writes no history
--skip-checksoffSkip the requirements pre-flight (the doctor checks that run first; they do not run with --dry-run anyway)

Uploads the latest successful build of each platform from history: .ipa to App Store Connect with pilot, .aab to Google Play with supply. Platforms submit independently. Before the upload, submit runs the requirements pre-flight for the submit actions, and a missing App Store Connect credential fails at once with MISSING_CONFIG_IOS_CREDENTIALS. In a terminal, with an Apple ID and no API key, it first asks Log in to your Apple account now? (Y/n) and logs in on your terminal (Ctrl-C aborts with exit 130 and uploads nothing); a failed login is APPLE_LOGIN_FAILED. The upload itself is piped and redacted. See App Store Connect and Google Play.

With --dry-run --json, each requested platform has status (ok, skipped or error), artifactPath, command and problems.

Exit 0 all succeeded or skipped, 1 any failed or no artifacts, 2 not initialized or iOS credentials missing.

Terminal window
rn-shipyard history [-p, --platform <ios|android>] [-l, --limit <n>]
FlagDefaultDescription
-p, --platform <platform>allFilter by ios or android
-l, --limit <limit>10Number of entries to show

Shows builds and submits from .shipyard/history.json as a table. The table is plain text (no colour codes) when stdout is not a terminal or NO_COLOR is set. Exit 0.

rn-shipyard is an independent open-source project, not affiliated with or endorsed by Expo. Expo and EAS are trademarks of 650 Industries, Inc.