Skip to content

Commit 8be71f2

Browse files
authored
Improve actions and format (#3)
* Improve actions and format * Update package.json
1 parent 8258c15 commit 8be71f2

3 files changed

Lines changed: 19 additions & 6 deletions

File tree

.github/workflows/ci.yml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,3 @@ jobs:
1616
run: yarn
1717
- name: Check Format
1818
run: yarn check-format
19-
- name: Run Tests
20-
run: yarn test
21-
- name: Coveralls GitHub Action
22-
uses: coverallsapp/github-action@v2

.github/workflows/deploy.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
name: Publish Package to npmjs
2+
on:
3+
release:
4+
types: [published]
5+
jobs:
6+
build:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- uses: actions/checkout@v4
10+
- uses: actions/setup-node@v4
11+
with:
12+
node-version: '18.16.0'
13+
registry-url: 'https://registry.npmjs.org'
14+
- run: npm ci
15+
- run: npm publish
16+
env:
17+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@
1414
"eslint": "eslint *.js",
1515
"eslint:fix": "yarn eslint --fix",
1616
"test": "echo \"Error: no test specified\" && exit 1",
17-
"format": "prettier --write \"{src/**/*,*}.{js,jsx,ts,tsx,css,md,json}\"",
18-
"check-format": "prettier -c \"{src/**/*,*}.{js,jsx,ts,tsx,css,md,json}\""
17+
"format": "prettier --write \"{src/**/*,.github/**/*,*}.{js,jsx,ts,tsx,css,md,json,yml}\"",
18+
"check-format": "prettier -c \"{src/**/*,.github/**/*,*}.{js,jsx,ts,tsx,css,md,json,yml}\""
1919
},
2020
"repository": {
2121
"type": "git",

0 commit comments

Comments
 (0)