Skip to content

Bash script to deploy to different Expo environments (https://expo.io)

License

Notifications You must be signed in to change notification settings

oliverbenns/expo-deploy

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

⚠️ Update

Expo now supports Release Channels! This script was created before that feature existed. You probably want to use them instead.

Expo Deploy

Bash script to deploy to different Expo environments.

It switches the relevant json file to be app.json before running the correct commands.

Setup

  • npm install exp -g
  • Place the deploy script in your root directory
  • Add the relevant config files as shown in this example repository
  • Add /app.json to your .gitignore.

Usage

  • Publish: ./deploy publish [environment]
  • Build: ./deploy build [environment] (builds both IPA + APK files)
  • Development: You'll want to copy the correct app file manually. E.g: cp ./config/staging.json ./app.json && react-native-scripts start. I haven't thought of a better way to do this yet.

Local Exp

It's also possible to have exp installed locally. To do this:

  • npm install exp --save-dev
  • In your package.json, call the shell script through npm scripts. This is how I do it:
    •   "publish": "chmod +x ./deploy.sh && ./deploy.sh publish $ENVIRONMENT",
        "build": "chmod +x ./deploy.sh && ./deploy.sh build $ENVIRONMENT"
      
    • Run withENVIRONMENT=staging npm run publish or ENVIRONMENT=staging npm run build

Releases

No releases published

Packages

No packages published

Languages