[AC-318] Support AdHoc vs. Production keys in config.json file
GitHub Issue | n/a |
---|---|
Type | Improvement |
Priority | n/a |
Status | Resolved |
Resolution | Duplicate |
Resolution Date | 2015-08-25T13:27:31.000+0000 |
Affected Version/s | n/a |
Fix Version/s | n/a |
Components | n/a |
Labels | n/a |
Reporter | Tim Poulsen |
Assignee | Shak Hossain |
Created | 2015-08-25T13:20:27.000+0000 |
Updated | 2015-08-25T13:27:31.000+0000 |
Description
Thanks to ALOY-680, you can differentiate between AdHoc and Appstore/Play Store builds in code (such as in alloy.js or your controllers). However, you cannot differentiate between such builds in the config.json.
We use different endpoints for AdHoc builds (Installr/TestFlight beta builds) vs our production releases. Currently, we have to manually copy & paste the contents of the config.json file to support such builds. This has resulted in mistakes. While we can use external tooling, like a grunt script, to manipulate the files, it would be best if Alloy itself supported something like:
{
"env:development": {"url":"https://dev.example.com"},
"env:test":{"url":"https://test.example.com"},
"env:production":{"url":"https://production.example.com"},
"dist:adhoc":{"url":"https://adhoc.example.com"},
"dist:store":{"url":"https://production.example.com"},
}
Given that we need this support for both iOS and Android, the key can't be env:adhoc
. In the above proposal, dist:adhoc
and dist:store
would need to override env:production
Ultimately, it would be great to use AdHoc/Store variables in TSS and XML files as well.
Duplicate of ALOY-1210