-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
d438f33
commit 2cf7230
Showing
5 changed files
with
2,700 additions
and
1,930 deletions.
There are no files selected for viewing
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,42 @@ | ||
name: deploy | ||
|
||
on: | ||
release: | ||
types: [created] | ||
|
||
jobs: | ||
deploy: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
|
||
- name: Cache | ||
uses: actions/cache@v3 | ||
id: cache-npm | ||
env: | ||
cache-name: cache-node-modules | ||
with: | ||
path: ~/.npm | ||
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }} | ||
restore-keys: | | ||
${{ runner.os }}-build-${{ env.cache-name }}- | ||
${{ runner.os }}-build- | ||
${{ runner.os }}- | ||
- name: NodeJS | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: '16' | ||
registry-url: https://registry.npmjs.org/ | ||
|
||
- name: Install | ||
run: | | ||
node --version | ||
npm --version | ||
npm ci | ||
- name: Publish | ||
run: npm publish | ||
env: | ||
NODE_AUTH_TOKEN: ${{ secrets.NPM_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,78 @@ | ||
name: test | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
pull_request: | ||
branches: | ||
- master | ||
workflow_dispatch: | ||
|
||
jobs: | ||
test: | ||
runs-on: ubuntu-latest | ||
env: | ||
DISPLAY: ':0' | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
|
||
- name: Cache | ||
uses: actions/cache@v3 | ||
id: cache-npm | ||
env: | ||
cache-name: cache-node-modules | ||
with: | ||
path: ~/.npm | ||
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }} | ||
restore-keys: | | ||
${{ runner.os }}-build-${{ env.cache-name }}- | ||
${{ runner.os }}-build- | ||
${{ runner.os }}- | ||
- name: NodeJS | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: '16' | ||
registry-url: https://registry.npmjs.org/ | ||
|
||
- name: Install | ||
run: | | ||
node --version | ||
npm --version | ||
npm ci | ||
- name: Lint | ||
run: | | ||
npm run lint | ||
npm run check-writing | ||
- name: Install Chrome | ||
uses: browser-actions/setup-chrome@latest | ||
|
||
- name: Install Firefox | ||
uses: browser-actions/setup-firefox@latest | ||
|
||
- name: Start Xvfb | ||
run: | | ||
sudo apt-get install xvfb && \ | ||
Xvfb $DISPLAY &> /dev/null & | ||
- name: Test | ||
run: npm run coverage | ||
env: | ||
KARMA_BROWSERS: Firefox,Chrome | ||
|
||
- name: Coveralls | ||
uses: coverallsapp/github-action@master | ||
with: | ||
github-token: ${{ secrets.GITHUB_TOKEN }} | ||
path-to-lcov: ${{ github.workspace }}/coverage/lcov.info | ||
|
||
- name: CodeClimate | ||
uses: paambaati/codeclimate-action@v3.0.0 | ||
env: | ||
CC_TEST_REPORTER_ID: ${{ secrets.CC_TEST_REPORTER_ID }} | ||
with: | ||
coverageLocations: ${{ github.workspace }}/coverage/lcov.info:lcov |
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 |
---|---|---|
@@ -1,3 +1,4 @@ | ||
node_modules | ||
build | ||
coverage | ||
.nyc_output |
Oops, something went wrong.