mirror of
https://github.com/expo/expo-github-action.git
synced 2026-11-15 17:32:45 -10:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
96ead1e418 | ||
|
|
cd75584edf | ||
|
|
3c768431d6 |
No files matched your search
@@ -1,3 +1,14 @@
|
||||
## [2.2.0](https://github.com/bycedric/ci-expo/compare/2.1.0...2.2.0) (2019-04-10)
|
||||
|
||||
### Code refactors
|
||||
|
||||
* use better expo cli variables prefix ([cd75584](https://github.com/bycedric/ci-expo/commit/cd75584))
|
||||
|
||||
### Documentation changes
|
||||
|
||||
* pin actions to versions for future releases ([3c76843](https://github.com/bycedric/ci-expo/commit/3c76843))
|
||||
|
||||
|
||||
## [2.1.0](https://github.com/bycedric/ci-expo/compare/2.0.0...2.1.0) (2019-04-10)
|
||||
|
||||
### Code refactors
|
||||
|
||||
@@ -10,7 +10,7 @@ You can also use [the base image](base) in other Docker-based environments.
|
||||
|
||||
Within this Expo CLI action, you have full access to the original [Expo CLI][link-expo-cli].
|
||||
That means you are able to perform any command like login, publish and build.
|
||||
Also, this action will authenticate automatically when both `EXPO_USERNAME` and `EXPO_PASSWORD` variables are defined.
|
||||
Also, this action will authenticate automatically when both `EXPO_CLI_USERNAME` and `EXPO_CLI_PASSWORD` variables are defined.
|
||||
|
||||
> You don't necessarily need this action to use Expo.
|
||||
> You can also add `expo-cli` as a dependency to your project and use the official [NPM action][link-actions-npm] for example.
|
||||
@@ -26,12 +26,12 @@ This makes the Expo actions overall faster.
|
||||
### Used secrets
|
||||
|
||||
To authenticate with your Expo account, use the variables listed below.
|
||||
In the Expo action you can define `secrets = ["EXPO_USERNAME", "EXPO_PASSWORD"]` to have them available.
|
||||
In the Expo action you can define `secrets = ["EXPO_CLI_USERNAME", "EXPO_CLI_PASSWORD"]` to have them available.
|
||||
|
||||
variable | description
|
||||
--- | ---
|
||||
`EXPO_USERNAME` | The email address or username of your Expo account.
|
||||
`EXPO_PASSWORD` | The password of your Expo account.
|
||||
variable | description
|
||||
--- | ---
|
||||
`EXPO_CLI_USERNAME` | The email address or username of your Expo account.
|
||||
`EXPO_CLI_PASSWORD` | The password of your Expo account, [automatically picked up by the cli][link-expo-cli-password].
|
||||
|
||||
> Some Expo commands don't require authentication.
|
||||
> Simply omit the `secrets = [...]` if you don't need it.
|
||||
@@ -58,15 +58,15 @@ workflow "Install and Publish" {
|
||||
}
|
||||
|
||||
action "Install" {
|
||||
uses = "actions/npm@master"
|
||||
uses = "actions/npm@1.0.0"
|
||||
args = "install"
|
||||
}
|
||||
|
||||
action "Publish" {
|
||||
needs = "Install"
|
||||
uses = "bycedric/ci-expo@master"
|
||||
uses = "byCedric/ci-expo@2.2.0"
|
||||
args = "publish"
|
||||
secrets = ["EXPO_USERNAME", "EXPO_PASSWORD"]
|
||||
secrets = ["EXPO_CLI_USERNAME", "EXPO_CLI_PASSWORD"]
|
||||
}
|
||||
```
|
||||
|
||||
@@ -83,13 +83,13 @@ workflow "Install and Publish" {
|
||||
}
|
||||
|
||||
action "Install" {
|
||||
uses = "actions/npm@master"
|
||||
uses = "actions/npm@1.0.0"
|
||||
args = "install"
|
||||
}
|
||||
|
||||
action "Test" {
|
||||
needs = "Install"
|
||||
uses = "actions/npm@master"
|
||||
uses = "actions/npm@1.0.0"
|
||||
args = "test"
|
||||
}
|
||||
|
||||
@@ -101,18 +101,16 @@ action "Filter branch" {
|
||||
|
||||
action "Publish" {
|
||||
needs = "Filter branch"
|
||||
uses = "bycedric/ci-expo@master"
|
||||
uses = "byCedric/ci-expo@2.2.0"
|
||||
args = "publish"
|
||||
secrets = ["EXPO_USERNAME", "EXPO_PASSWORD"]
|
||||
secrets = ["EXPO_CLI_USERNAME", "EXPO_CLI_PASSWORD"]
|
||||
}
|
||||
```
|
||||
|
||||
### Test and build web every day at 08:00
|
||||
|
||||
You can add as many extra steps in a workflow as you want.
|
||||
Here we've added a test step, that basically invokes `npm test` using the [NPM action][link-actions-npm].
|
||||
It also doesn't listen to push events.
|
||||
Instead, it's scheduled to run every day at 08:00.
|
||||
The most significant change here is that we've changed the workflow trigger.
|
||||
Instead of listening to push events, it's scheduled to run every day at 08:00.
|
||||
|
||||
> For web builds, you don't need to be authenticated.
|
||||
> That's why `secrets = [...]` is omitted here.
|
||||
@@ -124,19 +122,19 @@ workflow "Install, Test and Build Web" {
|
||||
}
|
||||
|
||||
action "Install" {
|
||||
uses = "actions/npm@master"
|
||||
uses = "actions/npm@1.0.0"
|
||||
args = "install"
|
||||
}
|
||||
|
||||
action "Test" {
|
||||
needs = "Install"
|
||||
uses = "actions/npm@master"
|
||||
uses = "actions/npm@1.0.0"
|
||||
args = "test"
|
||||
}
|
||||
|
||||
action "Publish" {
|
||||
needs = "Test"
|
||||
uses = "bycedric/ci-expo@master"
|
||||
uses = "byCedric/ci-expo@2.2.0"
|
||||
args = "build:web"
|
||||
}
|
||||
```
|
||||
@@ -155,3 +153,4 @@ The MIT License (MIT). Please see [License File](LICENSE.md) for more informatio
|
||||
[link-actions-npm]: https://github.com/actions/npm
|
||||
[link-expo]: https://expo.io
|
||||
[link-expo-cli]: https://docs.expo.io/versions/latest/workflow/expo-cli
|
||||
[link-expo-cli-password]: https://github.com/expo/expo-cli/blob/8ea616d8848a123270b97e226e33dcb3dde49653/packages/expo-cli/src/accounts.js#L94
|
||||
+2
-2
@@ -2,8 +2,8 @@
|
||||
|
||||
set -e
|
||||
|
||||
if [ -n "$EXPO_USERNAME" ] && [ -n "$EXPO_PASSWORD" ]; then
|
||||
expo login --username $EXPO_USERNAME --password $EXPO_PASSWORD
|
||||
if [ -n "$EXPO_CLI_USERNAME" ] && [ -n "$EXPO_CLI_PASSWORD" ]; then
|
||||
expo login --username $EXPO_CLI_USERNAME
|
||||
else
|
||||
echo 'Skipping Expo login, username and/or password not defined...'
|
||||
fi
|
||||
|
||||
Reference in new issue
Block a user