feat: cleanup and update #45
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CD | |
| on: | |
| push: | |
| branches: | |
| - master | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: checkout | |
| uses: actions/checkout@v1 | |
| - name: Configure CI Git User | |
| run: | | |
| git config --global user.name '@cirocfc' | |
| git config --global user.email 'ciro.cfc@gmail.com' | |
| git remote set-url origin https://$GITHUB_ACTOR:$GITHUB_TOKEN@github.com/cirocfc/yet-another | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GH_TK }} | |
| - name: Checkout and pull branch | |
| run: git checkout "${GITHUB_REF:11}" && git pull | |
| - name: Install Packages | |
| run: yarn install | |
| - name: Authenticate with Registry | |
| run: | | |
| echo "@cirocfc:registry=http://registry.npmjs.org/" > .npmrc | |
| echo "registry=http://registry.npmjs.org/" >> .npmrc | |
| echo "//registry.npmjs.org/:_authToken=$NPM_TOKEN" >> .npmrc | |
| npm whoami | |
| env: | |
| NPM_TOKEN: ${{ secrets.NPM_TOKEN }} | |
| - name: Publish package | |
| run: yarn release | |
| env: | |
| GH_TOKEN: ${{ secrets.GH_TK }} | |
| GITHUB_TOKEN: ${{ secrets.GH_TK }} | |
| NPM_TOKEN: ${{ secrets.NPM_TOKEN }} |