Skip to content

Commit

Permalink
ci: update workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
Necrelox committed Mar 22, 2024
1 parent 973ab87 commit ca3b997
Show file tree
Hide file tree
Showing 3 changed files with 47 additions and 12 deletions.
22 changes: 13 additions & 9 deletions .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
name: Test and Deploy Coverage
run-name: Test and Deploy Coverage
name: Test and Create badge to branch coverage
run-name: Test and Create badge to branch coverage
on:
push:
branches:
- stage
- main

jobs:
test:
Expand All @@ -12,16 +12,20 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Setup Node
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: 21.2
node-version: 21.7.1

- name: Install Dependencies
run: npm install

- name: Run Tests
run: npm run test
- name: Upload Coverage
uses: peaceiris/actions-gh-pages@v3

- name: Generating coverage badges
uses: jpb06/jest-badges-action@latest
with:
github_token: ${{ secrets.BASALT_TOKEN }}
publish_dir: ./coverage/lcov-report
branches: 'main'

31 changes: 31 additions & 0 deletions .github/workflows/docs-and-deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Generate docs and deploy to gh-pages
run-name: Generate docs and deploy to gh-pages
on:
push:
branches:
- main

jobs:
test:
name: Test
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 21.6.2

- name: Install Dependencies
run: npm install

- name: Generate Docs
run: npm run docs

- name: Upload Coverage
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.BASALT_TOKEN }}
publish_dir: ./docs
6 changes: 3 additions & 3 deletions .github/workflows/release-and-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,14 +33,14 @@ jobs:
uses: actions/checkout@v4
if: ${{ steps.release.outputs.release_created }}
- name: Publish
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: 21.2
node-version: 21.7.1
registry-url: 'https://registry.npmjs.org'
if: ${{ steps.release.outputs.release_created }}
- run: npm install
if: ${{ steps.release.outputs.release_created }}
- run: npm run build::pkg
- run: npm run pkg::build
if: ${{ steps.release.outputs.release_created }}
- run: npm ci
if: ${{ steps.release.outputs.release_created }}
Expand Down

0 comments on commit ca3b997

Please sign in to comment.