Skip to content
This repository was archived by the owner on Dec 30, 2022. It is now read-only.

Commit 172320f

Browse files
committed
chore: add a GitHub workflow for publishing
1 parent 4c228c8 commit 172320f

File tree

3 files changed

+591
-518
lines changed

3 files changed

+591
-518
lines changed

.github/main.workflow

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
workflow "Deploy" {
2+
on = "push"
3+
resolves = [
4+
"Release",
5+
"Pages",
6+
]
7+
}
8+
9+
action "Master" {
10+
uses = "actions/bin/filter@master"
11+
args = "branch master"
12+
}
13+
14+
action "Pages" {
15+
needs = "Master"
16+
uses = "satya164/node-app-tasks@master"
17+
secrets = ["GITHUB_TOKEN"]
18+
args = "gh-pages"
19+
}
20+
21+
action "Release" {
22+
needs = "Pages"
23+
uses = "satya164/node-app-tasks@master"
24+
secrets = ["NPM_AUTH_TOKEN", "GITHUB_TOKEN"]
25+
args = "release-it --non-interactive"
26+
}

package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
"prebuild": "del lib/",
1515
"prepare": "yarn build",
1616
"example": "parcel example/index.html",
17-
"gh-pages": "git branch -D gh-pages; git checkout -b gh-pages && rm -rf dist/ && parcel build example/App.js && git add -f dist/ && git commit -m 'Publish website' && git push -fu origin gh-pages; git checkout master",
17+
"gh-pages": "git branch -D gh-pages; git checkout -b gh-pages && rm -rf dist/ && parcel build example/App.js && git add -f dist/ && git commit -nm 'Publish website' && git push -fu origin gh-pages; git checkout @{-1}",
1818
"release": "release-it"
1919
},
2020
"husky": {
@@ -44,7 +44,7 @@
4444
"babel-plugin-transform-object-rest-spread": "^6.26.0",
4545
"babel-preset-env": "^1.7.0",
4646
"babel-preset-react": "^6.24.1",
47-
"conventional-changelog-cli": "^2.0.11",
47+
"conventional-changelog-cli": "^2.0.12",
4848
"dedent": "^0.7.0",
4949
"del-cli": "^1.1.0",
5050
"eslint": "^5.8.0",
@@ -57,7 +57,7 @@
5757
"prismjs": "^1.15.0",
5858
"react": "^16.6.0",
5959
"react-dom": "^16.6.0",
60-
"release-it": "^7.6.2"
60+
"release-it": "^10.3.1"
6161
},
6262
"peerDependencies": {
6363
"react": "^16.0.0",

0 commit comments

Comments
 (0)