Skip to content

Commit

Permalink
ci: add semantic-release (#6)
Browse files Browse the repository at this point in the history
  • Loading branch information
yqrashawn committed Jul 1, 2020
1 parent 86e8c93 commit f04d83b
Show file tree
Hide file tree
Showing 3 changed files with 2,854 additions and 93 deletions.
38 changes: 31 additions & 7 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,17 @@
version: 2
version: 2.1
workflows:
build_test_release:
jobs:
- test
- build
- release:
requires:
- build
- test
filters:
branches:
only: /^master|dev|alpha|[0-9]+\.[0-9]+\.x$/

jobs:
test:
docker:
Expand Down Expand Up @@ -47,9 +60,20 @@ jobs:
key: v2-dependencies-{{ checksum "package.json" }}

- run: yarn run build
workflows:
version: 2
build_and_test:
jobs:
- test
- build
- persist_to_workspace:
root: .
paths:
- dist
- esm

release:
docker:
- image: circleci/node:12.0

working_directory: ~/repo

steps:
- checkout
- attach_workspace:
at: .
- run: npx semantic-release
12 changes: 10 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
{
"name": "@conflux/react-ui",
"name": "@confi/conflux-react-ui-test-package",
"version": "0.0.0",
"main": "dist/index.js",
"module": "esm/index.js",
"types": "dist/index.d.ts",
"unpkg": "dist/index.min.js",
"license": "MIT",
"description": "Modern and minimalist React UI library.",
"homepage": "https://react-ui.conflux-chain.org",
"homepage": "https://conflux-react-ui.vercel.app",
"bugs": {
"url": "https://github.com/Conflux-Chain/react-ui/issues/new/choose"
},
Expand Down Expand Up @@ -100,6 +100,7 @@
"react-color": "^2.18.0",
"react-dom": "^16.13.1",
"react-live": "^2.2.2",
"semantic-release": "^17.1.1",
"ts-jest": "^25.3.1",
"typescript": "^3.8.3",
"webpack": "^4.41.6",
Expand All @@ -112,5 +113,12 @@
"commitizen": {
"path": "./node_modules/cz-conventional-changelog"
}
},
"release": {
"plugins": ["@semantic-release/commit-analyzer", "@semantic-release/release-notes-generator", "@semantic-release/npm", "@semantic-release/github"],
"branches": [
"+([0-9])?(.{+([0-9]),x}).x", "master",
{ "name": "dev", "channel": "alpha", "prerelease": "alpha" }
]
}
}
Loading

0 comments on commit f04d83b

Please sign in to comment.