Browse Source

update ci

nameczz 3 years ago
parent
commit
d86367acd7
3 changed files with 18 additions and 9 deletions
  1. 5 7
      .github/workflows/release.yml
  2. 1 0
      .gitignore
  3. 12 2
      package.json

+ 5 - 7
.github/workflows/release.yml

@@ -1,7 +1,6 @@
 on:
-  push:
-    branches:
-      - main
+  release:
+    types: [published]
 
 jobs:
   publish:
@@ -12,8 +11,7 @@ jobs:
         uses: actions/setup-node@v1
         with:
           node-version: 12
-
       - name: Semantic release
-        env:
-          GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
-        run: npx semantic-release
+        run: |
+          yarn
+          npx semantic-release

+ 1 - 0
.gitignore

@@ -1,6 +1,7 @@
 # See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
 
 # dependencies
+node_modules
 /client/node_modules
 /client/build
 /.pnp

+ 12 - 2
package.json

@@ -1,6 +1,6 @@
 {
   "name": "milvus-insight",
-  "version": "0.1.0",
+  "version": "0.0.0-development",
   "description": "Milvus insight",
   "license": "Apache-2.0",
   "bugs": "https://github.com/milvus-io/milvus-insight/issues",
@@ -11,5 +11,15 @@
   },
   "publishConfig": {
     "access": "public"
+  },
+  "scripts": {
+    "semantic-release": "semantic-release"
+  },
+  "repository": {
+    "type": "git",
+    "url": "https://github.com/nameczz/milvus-insight.git"
+  },
+  "devDependencies": {
+    "semantic-release": "^17.4.4"
   }
-}
+}