Skip to content

Commit 46d9e77

Browse files
authored
Merge pull request #11 from CodinGame/add-ci
Add CI
2 parents 58d688f + c71956a commit 46d9e77

File tree

4 files changed

+177
-4
lines changed

4 files changed

+177
-4
lines changed

.github/workflows/release.yml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
branches: [main]
6+
7+
jobs:
8+
release:
9+
name: Release
10+
runs-on: ubuntu-latest
11+
12+
steps:
13+
- name: Checkout
14+
uses: actions/checkout@v2
15+
- name: Setup Node.js
16+
uses: actions/setup-node@v1
17+
with:
18+
node-version: 16.x
19+
- name: Install dependencies
20+
run: npm ci
21+
- name: Build
22+
run: npm run build
23+
- name: Release
24+
env:
25+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
26+
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
27+
run: npx semantic-release

package-lock.json

Lines changed: 124 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
11
{
22
"name": "@codingame/monaco-languageclient-react",
3-
"version": "2.1.0",
3+
"version": "0.0.0-semantic-release",
44
"description": "Monaco Editor React component",
55
"scripts": {
66
"build": "tsc",
7-
"prepublishOnly": "npm run build",
87
"lint": "npx eslint src/**"
98
},
109
"repository": {
@@ -36,6 +35,7 @@
3635
"@typescript-eslint/eslint-plugin": "5.15.0",
3736
"@typescript-eslint/parser": "5.15.0",
3837
"babel-eslint": "10.1.0",
38+
"conventional-changelog-conventionalcommits": "^4.6.3",
3939
"eslint": "8.11.0",
4040
"eslint-config-standard": "16.0.3",
4141
"eslint-config-standard-jsx": "10.0.0",

release.config.js

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
module.exports = {
2+
branches: [
3+
'main'
4+
],
5+
plugins: [
6+
['@semantic-release/commit-analyzer', {
7+
preset: 'conventionalcommits',
8+
releaseRules: [
9+
{ type: 'ci', release: 'patch' },
10+
{ type: 'style', release: 'patch' },
11+
{ type: 'refactor', release: 'patch' },
12+
{ type: 'cleanup', release: 'patch' },
13+
{ type: 'docs', release: 'patch' },
14+
{ type: 'perfs', release: 'patch' },
15+
{ type: 'test', release: 'patch' },
16+
{ type: 'libs', release: 'patch' },
17+
{ type: 'chore', release: 'patch' },
18+
]
19+
}],
20+
'@semantic-release/release-notes-generator',
21+
'@semantic-release/npm',
22+
'@semantic-release/github'
23+
]
24+
}

0 commit comments

Comments
 (0)