Merge pull request #164 from julianbenegas/master #208
This file contains 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: Npm Packages | |
on: | |
push: | |
# branches: | |
# - master | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
submodules: true | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: 18 | |
registry-url: https://registry.npmjs.org/ | |
- name: Cache pnpm modules | |
uses: actions/cache@v3 | |
with: | |
path: ~/pnpm | |
key: ${{ runner.os }}-${{ hashFiles('**/pnpm-lock.yaml') }} | |
restore-keys: | | |
${{ runner.os }}- | |
# setup pnpm | |
- uses: pnpm/action-setup@v2 | |
with: | |
version: 8 | |
run_install: false | |
# scripts | |
- run: pnpm i --store-dir ~/pnpm | |
- run: pnpm buildall | |
- run: pnpm genall | |
- run: pnpm test | |
# - name: Bump version | |
# if: github.ref == 'refs/heads/master' || github.ref == 'refs/heads/fields-selection' | |
# uses: remorses/bump-version@js | |
# with: | |
# version_file: VERSION | |
# env: | |
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
# - run: yarn buildall | |
# - name: Publish | |
# run: | | |
# cd genql-cli && npm publish --verbose --access public --tag beta | |
# cd ../genql-runtime && npm publish --verbose --access public --tag beta | |
# if: github.ref == 'refs/heads/master' || github.ref == 'refs/heads/fields-selection' | |
# env: | |
# NODE_AUTH_TOKEN: ${{ secrets.npm_token }} |