This repository was archived by the owner on Nov 24, 2024. It is now read-only.
chore(deps-dev): bump eslint-plugin-jest from 27.2.1 to 28.9.0 (#568) #118
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: π Continuous deployment | |
on: | |
push: | |
branches: | |
- main | |
workflow_dispatch: | |
inputs: | |
version: | |
type: choice | |
description: Version | |
required: true | |
options: | |
- patch | |
- minor | |
- major | |
env: | |
NODE_VERSION: 22 | |
REGISTRY_URL: 'https://registry.npmjs.org' | |
GIT_USER_NAME: tokenstreet-tools | |
GIT_USER_EMAIL: tools@tokenstreet.com | |
jobs: | |
deploy_website: | |
name: π Deploy website | |
runs-on: ubuntu-latest | |
if: github.event_name == 'push' | |
steps: | |
- name: π Cancel Previous Runs | |
uses: styfle/cancel-workflow-action@0.12.1 | |
- name: β¬οΈ Checkout repo | |
uses: actions/checkout@v4 | |
- name: β Setup node | |
uses: actions/setup-node@v4 | |
with: | |
node-version: ${{ env.NODE_VERSION }} | |
registry-url: ${{ env.REGISTRY_URL }} | |
- name: π₯ Download deps | |
uses: bahmutov/npm-install@v1 | |
- run: yarn --cwd packages/website build | |
- name: Deploy to GitHub Pages | |
uses: peaceiris/actions-gh-pages@v4 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: ./packages/website/build | |
user_name: ${{ env.GIT_USER_NAME }} | |
user_email: ${{ env.GIT_USER_EMAIL }} | |
publish_package: | |
name: β¬οΈ Publish package | |
runs-on: ubuntu-latest | |
if: github.event_name == 'workflow_dispatch' | |
steps: | |
- name: π Cancel Previous Runs | |
uses: styfle/cancel-workflow-action@0.12.1 | |
- name: β¬οΈ Checkout repo | |
uses: actions/checkout@v4 | |
with: | |
token: ${{ secrets.PERSONAL_ACCESS_TOKEN_TOOLS_TOKENSTREET }} | |
- name: Set git credentials | |
run: | | |
git config --global user.name "${{ env.GIT_USER_NAME }}" | |
git config --global user.email "${{ env.GIT_USER_EMAIL }}" | |
- name: β Setup node | |
uses: actions/setup-node@v4 | |
with: | |
node-version: ${{ env.NODE_VERSION }} | |
registry-url: ${{ env.REGISTRY_URL }} | |
- name: π₯ Download deps | |
uses: bahmutov/npm-install@v1 | |
- name: Copy README.md | |
run: cp README.md ./packages/core/README.md | |
- run: yarn version --${{ github.event.inputs.version }} | |
working-directory: ./packages/core | |
- run: git push --follow-tags | |
- run: yarn publish | |
working-directory: ./packages/core | |
env: | |
NODE_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }} |