npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

rn-ci-setup

v1.0.7

Published

CLI to scaffold React Native CI/CD and manage CI secrets

Readme

rn-ci-setup

npm version

rn-ci-setup is a production-focused CLI to automate React Native CI/CD setup with GitHub Actions, Fastlane, signing, and GitHub Secrets management.

It is designed for teams that want a guided, repeatable setup flow with minimal manual file creation.

Install

npm i -g rn-ci-setup

or run without global install:

npx rn-ci-setup init

What It Automates

When you run init, the CLI orchestrates the full setup pipeline:

  1. Validates Git repository state and bootstrap behavior
  2. Creates GitHub repo with gh when origin is missing
  3. Lets you choose the working branch and syncs it
  4. Collects platform and template options
  5. Configures optional Slack/Discord/Teams notifications
  6. Generates GitHub workflows and Fastlane files
  7. Runs Bundler setup
  8. Runs interactive Fastlane setup commands
  9. Configures GitHub Actions secrets via gh
  10. Commits and pushes generated files (unless skipped)

Commands

init

npx rn-ci-setup init

Common flags:

  • --ci-provider <github|bitrise|codemagic>: choose CI provider (default: github)
  • --android / --ios: target platforms
  • --expo / --bare: project template
  • --notify-slack: enable Slack notification integration
  • --notify-discord: enable Discord notification integration
  • --notify-teams: enable Microsoft Teams notification integration
  • --app-path <path>: target app path for monorepos
  • --skip-bundle: skip bundle install
  • --skip-fastlane: skip Fastlane initialization/signing commands
  • --skip-secrets: skip GitHub secrets setup
  • --skip-push: skip commit/push stage

Examples:

npx rn-ci-setup init --ci-provider github --android --ios
npx rn-ci-setup init --ci-provider bitrise --android --ios
npx rn-ci-setup init --ci-provider codemagic --ios --app-path apps/mobile
npx rn-ci-setup init --ios --app-path apps/mobile
npx rn-ci-setup init --android --ios --notify-slack --notify-teams
npx rn-ci-setup init --android --ios --skip-fastlane --skip-secrets

secrets

Creates or updates required GitHub Actions secrets using GitHub CLI:

npx rn-ci-setup secrets

Optional repo override:

npx rn-ci-setup secrets --repo owner/repo

keys

Prints a guided checklist to generate platform API keys and map them to the expected GitHub Actions secrets.

npx rn-ci-setup keys

Platform-scoped usage:

npx rn-ci-setup keys --ios
npx rn-ci-setup keys --android
npx rn-ci-setup keys --ios --android

doctor

Checks required CI/CD values and warns on missing or weak placeholders:

npx rn-ci-setup doctor

Generated Artifacts

Depending on selected targets, init generates:

  • .github/workflows/android.yml (GitHub provider)
  • .github/workflows/ios.yml (GitHub provider)
  • bitrise.yml (Bitrise provider)
  • codemagic.yaml (Codemagic provider)
  • Gemfile (ensures Fastlane dependency)
  • ios/fastlane/Fastfile
  • ios/fastlane/Appfile
  • ios/fastlane/Matchfile
  • android/fastlane/Fastfile
  • .rn-ci-setup.json

CI Provider Notes

  • GitHub: full automation path, including GitHub Actions secrets via gh.
  • Bitrise: generates bitrise.yml and Fastlane files; secrets must be added in Bitrise dashboard.
  • Codemagic: generates codemagic.yaml and Fastlane files; secrets must be added in Codemagic dashboard.

For Bitrise/Codemagic projects, --skip-secrets is effectively implied because GitHub secret automation is not used.

Fastlane Flow Executed by CLI

For iOS, the CLI supports this setup flow:

  • cd ios && bundle exec fastlane init (if missing)
  • cd ios && bundle exec fastlane match init (if needed)
  • cd ios && bundle exec fastlane match appstore
  • cd ios && bundle exec fastlane match development

For Android, the CLI initializes Fastlane when needed:

  • cd android && bundle exec fastlane init

Workflow Trigger Strategy

Generated workflows follow this model:

  • pull_request to main/master: run CI lanes
  • push to main/master: run beta/distribution lanes
  • workflow_dispatch: manual release lanes

Required Secrets (GitHub Actions)

iOS

  • APP_STORE_CONNECT_KEY_ID
  • APP_STORE_CONNECT_ISSUER_ID
  • APP_STORE_CONNECT_PRIVATE_KEY
  • MATCH_GIT_URL
  • MATCH_PASSWORD
  • APPLE_APP_IDENTIFIER
  • APPLE_TEAM_ID

Recommended:

  • APP_STORE_CONNECT_TEAM_ID
  • FASTLANE_USER

Android

  • ANDROID_KEYSTORE_BASE64
  • ANDROID_KEYSTORE_PASSWORD
  • ANDROID_KEY_ALIAS
  • ANDROID_KEY_PASSWORD

Notifications (optional)

  • SLACK_WEBHOOK_URL
  • DISCORD_WEBHOOK_URL
  • TEAMS_WEBHOOK_URL

API Key Generation Guide

You can print this guide anytime from CLI:

npx rn-ci-setup keys --ios --android

App Store Connect API Key (iOS)

  1. Open App Store Connect -> Users and Access -> Integrations -> App Store Connect API.
  2. Generate a key and download the .p8 file.
  3. Capture:
    • Key ID
    • Issuer ID
    • Full .p8 key content
  4. Add these secrets:
    • APP_STORE_CONNECT_KEY_ID
    • APP_STORE_CONNECT_ISSUER_ID
    • APP_STORE_CONNECT_PRIVATE_KEY
  5. Ensure iOS signing secrets are also configured:
    • MATCH_GIT_URL
    • MATCH_PASSWORD
    • APPLE_APP_IDENTIFIER
    • APPLE_TEAM_ID

Google Play Console API Key (Android)

  1. Open Google Play Console -> Setup -> API access.
  2. Link a Google Cloud project.
  3. Create a service account in Google Cloud IAM.
  4. Grant required Play Console permissions to that service account.
  5. Create and download the service account JSON key.
  6. If your Android release lanes need base64:
base64 -i play-service-account.json | tr -d '\n'
  1. Configure Android signing secrets:
    • ANDROID_KEYSTORE_BASE64
    • ANDROID_KEYSTORE_PASSWORD
    • ANDROID_KEY_ALIAS
    • ANDROID_KEY_PASSWORD

Prerequisites

  • Node.js and npm
  • Git
  • GitHub CLI (gh) authenticated
  • Ruby and Bundler
  • Xcode/CocoaPods for iOS pipelines
  • Android toolchain for Android pipelines

Local Development

npm install
node ./bin/index.js --help
node ./bin/index.js init
node ./bin/index.js secrets
node ./bin/index.js doctor

Release to npm

npm version patch
npm publish

Use minor or major version bumps when appropriate.