Skip to content

Commit

Permalink
chore: add deployment logic (#1)
Browse files Browse the repository at this point in the history
  • Loading branch information
buehler authored Oct 21, 2022
1 parent 2629406 commit 9d0d718
Show file tree
Hide file tree
Showing 9 changed files with 2,799 additions and 4,787 deletions.
24 changes: 24 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Release npm package
on:
push:
branches:
- 'main'

jobs:
release:
name: test build and release
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
submodules: true
- uses: actions/setup-node@v3
with:
node-version: 18
- run: npm ci
- run: npm run build
- name: semantic release
uses: cycjimmy/semantic-release-action@v3
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
36 changes: 36 additions & 0 deletions .github/workflows/testing.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Test Package
on:
pull_request:
branches:
- '**'

jobs:
test_matrix:
strategy:
fail-fast: true
matrix:
version:
- 16
- 18
name: test and build package (node ${{ matrix.version }})
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
submodules: true
- uses: actions/setup-node@v3
with:
node-version: ${{ matrix.version }}
- run: npm ci
- run: npm run build
- run: npm test

test_all:
if: ${{ always() }}
runs-on: ubuntu-latest
name: Test (matrix)
needs: test_matrix
steps:
- name: Check test matrix status
if: ${{ needs.test_matrix.result != 'success' }}
run: exit 1
6 changes: 6 additions & 0 deletions ava.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
module.exports = {
files: ['test/**/*.test.ts'],
verbose: true,
extensions: ['ts'],
require: ['ts-node/register'],
};
7 changes: 0 additions & 7 deletions jest.config.js

This file was deleted.

Loading

0 comments on commit 9d0d718

Please sign in to comment.