7

I've been showing my team my progress with the Staging key. When I do code-push deployment ls APP_NAME_HERE -k, it'll give me a Staging and Production table with Production having the message No updates released.

I have been using code-push release-react APP_NAME_HERE ios to update. Can anyone guide me as to what options I need to send to Production instead of Staging?

Naoto Ida
  • 1,275
  • 1
  • 14
  • 29

1 Answers1

24

You can use --deploymentName to specify the deployment you want to update.

code-push release-react APP_NAME_HERE ios --deploymentName Production

You could also promote your release from staging to production (docs):

code-push promote APP_NAME_HERE Staging Production

Daniel Basedow
  • 13,048
  • 2
  • 32
  • 30
  • Thank you so much! – Naoto Ida Jun 03 '16 at 15:11
  • 2
    Does the key I set in my info.plist file in xcode have to be the staging key then? What should the value of that key be, staging or production? – samonderous Jul 22 '16 at 08:57
  • You should create a separate Info-Staging.plist and use that for staging and put the production key into Info.plist. You could also put a placeholder $(CODE_PUSH_KEY) into Info.plist and replace it during the build with an environment variable defined in the scheme. – Daniel Basedow Jul 22 '16 at 10:28
  • 4
    so if I want to have a two versions, one for testing one for production I need to build and release two packages, in case of Android it will be an apk file so it's easy to share what should I do for IOS? submit both to Apple store? – demsey Oct 28 '16 at 12:14
  • @demsey ever find an answer to this question? Should the staging app be a separate app? – Uri Klar Feb 01 '17 at 07:01
  • no I didn't, for IOS I have only production app, for Android both test and production – demsey Feb 02 '17 at 14:53