Skip to content

Commit

Permalink
Create GitHub action to publish npm package
Browse files Browse the repository at this point in the history
  • Loading branch information
lym953 committed Oct 10, 2024
1 parent 6d0e78b commit cc07a5f
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 9 deletions.
12 changes: 12 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
name: Publish packages on NPM
on:
push:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: "18.x"
- run: echo "Hello world!"
9 changes: 0 additions & 9 deletions scripts/publish_prod.sh
Original file line number Diff line number Diff line change
Expand Up @@ -68,9 +68,6 @@ if [ "$UPDATE_LAYERS" != "false" ]; then
fi
fi

# Verify NPM access before updating layer arns (slow)
yarn login

if [ "$UPDATE_LAYERS" != "false" ]; then
aws-vault exec sso-govcloud-us1-fed-engineering -- aws sts get-caller-identity
aws-vault exec sso-prod-engineering -- aws sts get-caller-identity
Expand All @@ -92,12 +89,6 @@ echo
echo "Bumping the version number and committing the changes"
yarn version --new-version "$VERSION"

echo
echo 'Publishing to npm'
yarn
yarn build
yarn publish --new-version "$VERSION"

echo
echo 'Pushing updates to GitHub'
git push origin main
Expand Down

0 comments on commit cc07a5f

Please sign in to comment.