Skip to content

Commit fb71663

Browse files
committed
Fix: actions workflow
1 parent 240059c commit fb71663

File tree

3 files changed

+46
-29
lines changed

3 files changed

+46
-29
lines changed

.github/workflows/auto-update.yml

+13-12
Original file line numberDiff line numberDiff line change
@@ -36,14 +36,8 @@ jobs:
3636
add: 'package*.json'
3737
message: 'Bot: npm deps update'
3838

39-
- name: Update npm dependencies
40-
run: |
41-
npm version patch --no-git-tag-version
42-
npm update
43-
npm run build
44-
npm run test --if-present
45-
46-
- uses: actions/upload-artifact@v4
39+
- name: Store build artifacts
40+
uses: actions/upload-artifact@v4
4741
with:
4842
name: build-artifacts
4943
path: |
@@ -54,15 +48,22 @@ jobs:
5448
needs: update-deps
5549
runs-on: ubuntu-latest
5650
steps:
57-
- uses: actions/checkout@v4
58-
- uses: actions/setup-node@v3
51+
- name: Checkout repository
52+
uses: actions/checkout@v4
53+
54+
- name: Set up Node.js
55+
uses: actions/setup-node@v3
5956
with:
6057
node-version: 20
6158
registry-url: https://registry.npmjs.org/
62-
- uses: actions/download-artifact@v4
59+
60+
- name: Download build artifacts
61+
uses: actions/download-artifact@v4
6362
with:
6463
name: build-artifacts
6564
path: dist
66-
- run: npm publish
65+
66+
- name: Publish to npm
67+
run: npm publish
6768
env:
6869
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

.github/workflows/npm-publish.yml

+31-15
Original file line numberDiff line numberDiff line change
@@ -12,21 +12,30 @@ jobs:
1212
build:
1313
runs-on: ubuntu-latest
1414

15-
strategy:
16-
matrix:
17-
node-version: [20.x]
18-
1915
steps:
20-
- uses: actions/checkout@v4
21-
- name: Use Node.js ${{ matrix.node-version }}
16+
- name: Checkout repository
17+
uses: actions/checkout@v4
18+
19+
- name: Set up Node.js
2220
uses: actions/setup-node@v3
2321
with:
24-
node-version: ${{ matrix.node-version }}
22+
node-version: 20
2523
cache: 'npm'
26-
- run: npm ci
27-
- run: npm run build
28-
- run: npm run test --if-present
29-
- uses: actions/upload-artifact@v4
24+
25+
- name: Update npm dependencies
26+
run: |
27+
npm ci
28+
npm run build
29+
npm run test --if-present
30+
31+
- name: Commit and push changes
32+
uses: EndBug/add-and-commit@v9
33+
with:
34+
add: 'package*.json'
35+
message: 'Bot: npm deps update'
36+
37+
- name: Store build artifacts
38+
uses: actions/upload-artifact@v4
3039
with:
3140
name: build-artifacts
3241
path: |
@@ -37,15 +46,22 @@ jobs:
3746
needs: build
3847
runs-on: ubuntu-latest
3948
steps:
40-
- uses: actions/checkout@v4
41-
- uses: actions/setup-node@v3
49+
- name: Checkout repository
50+
uses: actions/checkout@v4
51+
52+
- name: Set up Node.js
53+
uses: actions/setup-node@v3
4254
with:
4355
node-version: 20
4456
registry-url: https://registry.npmjs.org/
45-
- uses: actions/download-artifact@v4
57+
58+
- name: Download build artifacts
59+
uses: actions/download-artifact@v4
4660
with:
4761
name: build-artifacts
4862
path: dist
49-
- run: npm publish
63+
64+
- name: Publish to npm
65+
run: npm publish
5066
env:
5167
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

package.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "hivessh",
3-
"version": "1.1.7",
3+
"version": "1.1.10",
44
"description": "HiveSsh simplifies SSH2 connections via promise-based task execution on Linux servers with built-in server utilities and powerful command execution functions",
55
"main": "dist/index.js",
66
"type": "module",
@@ -63,4 +63,4 @@
6363
"dependencies": {
6464
"ssh2": "^1.15.0"
6565
}
66-
}
66+
}

0 commit comments

Comments
 (0)