Skip to content

Commit

Permalink
feat: workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
Nelfimov committed Jan 31, 2024
1 parent 293bb7d commit f7f229d
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 76 deletions.
56 changes: 12 additions & 44 deletions .github/workflows/checks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,47 +3,15 @@ name: Checks
on: [pull_request]

jobs:
run:
name: Run
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v3

- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: '18.13'

- name: Install
run: yarn install
env:
GITHUB_TOKEN: '${{ secrets.GITHUB_TOKEN }}'

- name: Lint
run: yarn checks lint
env:
GITHUB_TOKEN: '${{ secrets.GITHUB_TOKEN }}'

- name: TypeCheck
run: yarn checks typecheck
env:
GITHUB_TOKEN: '${{ secrets.GITHUB_TOKEN }}'

- name: TestUnit
run: yarn checks test unit
env:
GITHUB_TOKEN: '${{ secrets.GITHUB_TOKEN }}'
NODE_OPTIONS: --experimental-vm-modules

- name: TestIntegration
run: yarn checks test integration
env:
GITHUB_TOKEN: '${{ secrets.GITHUB_TOKEN }}'
NODE_OPTIONS: --experimental-vm-modules

- name: Release
run: yarn checks release
env:
GITHUB_TOKEN: '${{ secrets.GITHUB_TOKEN }}'
check:
name: Typecheck, lint
uses: atls/tools/.github/workflows/reusable-checks.yaml@master
permissions: write-all
release:
name: Release
uses: atls/tools/.github/workflows/reusable-release.yaml@master
permissions: write-all
test:
name: Tests
uses: atls/tools/.github/workflows/reusable-tests.yaml@master
permissions: write-all
37 changes: 5 additions & 32 deletions .github/workflows/publish.yaml
Original file line number Diff line number Diff line change
@@ -1,38 +1,11 @@
name: Publish

on:
workflow_dispatch:
on: [pull_request]

jobs:
run:
name: Publish
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v3

- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: '18.13'

- name: Install
run: yarn install

- name: Npm Publish
run: |
yarn version apply --all
yarn workspaces changed foreach --verbose --topological --no-private npm publish --access public
env:
YARN_NPM_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

- name: Commit changes
uses: EndBug/add-and-commit@v9
env:
GITHUB_TOKEN: '${{ secrets.GITHUB_TOKEN }}'
with:
author_name: Atls Github Bot
author_email: [email protected]
message: 'chore(common): publish'
branch: master
uses: atls/tools/.github/workflows/reusable-publish.yaml@master
permissions: write-all
secrets:
npmAuthToken: ${{ secrets.NPM_TOKEN }}

0 comments on commit f7f229d

Please sign in to comment.