-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: migrate ci to github actions (#258)
* ci: deprecate circleci * ci: migrate to github actions
- Loading branch information
Showing
5 changed files
with
139 additions
and
36 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
on: | ||
workflow_call: | ||
|
||
env: | ||
NODE_ENV: ci | ||
|
||
name: "Linters" | ||
|
||
jobs: | ||
lint: | ||
name: Code Lint | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-node@v3 | ||
with: | ||
node-version: 14.x | ||
- run: npm ci --ignore-scripts | ||
- run: npm run lint | ||
|
||
commit-lint: | ||
name: Commit Lint | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Install Commit Lint Dependencies | ||
run: npm install @commitlint/config-conventional | ||
- uses: JulienKode/pull-request-name-linter-action@v0.5.0 |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
on: | ||
pull_request: | ||
types: [ opened, reopened, synchronize ] | ||
|
||
env: | ||
NODE_ENV: ci | ||
|
||
name: "Pull Requests" | ||
|
||
jobs: | ||
tests: | ||
name: Tests | ||
uses: ./.github/workflows/tests.yml | ||
|
||
linters: | ||
name: Linters | ||
uses: ./.github/workflows/linters.yml | ||
|
||
eslint-review: | ||
name: ESLint Review | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: read | ||
pull-requests: write | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: reviewdog/action-eslint@v1 | ||
with: | ||
github_token: ${{ secrets.GITHUB_TOKEN }} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
on: | ||
push: | ||
branches: | ||
- master | ||
- beta | ||
- +([0-9])?(.{+([0-9]),x}).x | ||
|
||
env: | ||
NODE_ENV: ci | ||
|
||
name: Release | ||
|
||
jobs: | ||
tests: | ||
name: Tests | ||
uses: ./.github/workflows/tests.yml | ||
|
||
linters: | ||
name: Linters | ||
uses: ./.github/workflows/linters.yml | ||
|
||
release: | ||
name: Publish Release | ||
runs-on: ubuntu-latest | ||
needs: [ tests, linters ] | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-node@v3 | ||
with: | ||
node-version: 14.x | ||
- run: npm ci | ||
- run: npm run build | ||
- uses: codfish/semantic-release-action@v2 | ||
id: semantic | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} | ||
- name: Output new release version | ||
if: steps.semantic.outputs.new-release-published == 'true' | ||
run: | | ||
echo "🎉New Release Published: ${{ steps.semantic.outputs.release-version }}" |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
on: | ||
workflow_call: | ||
|
||
env: | ||
NODE_ENV: ci | ||
|
||
name: "Tests" | ||
|
||
jobs: | ||
run-tests: | ||
name: Run Tests | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-node@v3 | ||
with: | ||
node-version: 14.x | ||
- run: npm ci | ||
- run: npm run test -- --runInBand | ||
|
||
test-build: | ||
name: Test Build | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-node@v3 | ||
with: | ||
node-version: 14.x | ||
- run: npm ci | ||
- run: npm run build | ||
|
||
wrap-benchmark: | ||
name: Benchmark Wrap Functionality | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-node@v3 | ||
with: | ||
node-version: 14.x | ||
- run: npm ci | ||
- run: npm run benchmark |