Skip to content

Commit

Permalink
refactor: authenticate in main action if possible
Browse files Browse the repository at this point in the history
  • Loading branch information
byCedric committed Apr 10, 2019
1 parent 48bbaf3 commit a401e30
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 1 deletion.
6 changes: 5 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
FROM bycedric/ci-expo:2

LABEL com.github.actions.name="Expo CLI (unofficial)"
LABEL com.github.actions.description="Use any Expo command in your GitHub Actions workflow."
LABEL com.github.actions.description="Use any Expo CLI command in your GitHub Actions workflow."
LABEL com.github.actions.icon="terminal"
LABEL com.github.actions.color="gray-dark"

COPY entrypoint.sh LICENSE.md README.md /

entrypoint ["/entrypoint.sh"]
11 changes: 11 additions & 0 deletions entrypoint.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/bin/sh -l

set -e

if [ -n "$EXPO_USERNAME" ] && [ -n "$EXPO_PASSWORD" ]; then
expo login --username $EXPO_USERNAME --password $EXPO_PASSWORD
else
echo 'Skipping Expo login, username and/or password not defined...'
fi

sh -c "expo $*"

0 comments on commit a401e30

Please sign in to comment.