-
Hi everyone! I need to set $APP_STORE_CONNECT_PRIVATE_KEY and other global vars in codemagic.yaml file. Not in "Environment variables" tab! Inside codemagic.yaml) But! If i set in one script then after try read in another script var is not available. And not available in publishing. How to solve this problem? Thanks! |
Beta Was this translation helpful? Give feedback.
Answered by
todah-zg
Oct 19, 2022
Replies: 1 comment
-
Please follow this guide on how to set environment variables during builds. In short, you can save the variable to the $CM_ENV file in one script to be able to access it in subsequent scripts. scripts:
- name: Step 1
script: |
echo "APP_STORE_CONNECT_PRIVATE_KEY='my secret value'" >> $CM_ENV
- name: Step 2
script: |
echo $APP_STORE_CONNECT_PRIVATE_KEY |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
gopherios
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Please follow this guide on how to set environment variables during builds.
In short, you can save the variable to the $CM_ENV file in one script to be able to access it in subsequent scripts.