Skip to content

Commit 790103e

Browse files
Update package version to 1.0.3, enhance CI/CD workflows, and refactor vipstar hashing function.
- Bump version in package.json and package-lock.json. - Modify CircleCI and GitHub Actions workflows to run tests across multiple Node.js versions. - Refactor vipstar_hash function to accept input length and change parameter types for better memory management.
1 parent 2cef7cc commit 790103e

File tree

7 files changed

+624
-229
lines changed

7 files changed

+624
-229
lines changed

.circleci/config.yml

Lines changed: 47 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,11 @@ jobs:
1111
name: Run build
1212
command: npm install
1313
- run:
14-
name: Verify build
15-
command: echo "Build completed successfully!"
14+
name: Run test
15+
command: npm run test
16+
- run:
17+
name: Verify build and test
18+
command: echo "Build and test completed successfully!"
1619
test-v10:
1720
docker:
1821
- image: cimg/base:stable
@@ -24,8 +27,11 @@ jobs:
2427
name: Run build
2528
command: npm install
2629
- run:
27-
name: Verify build
28-
command: echo "Build completed successfully!"
30+
name: Run test
31+
command: npm run test
32+
- run:
33+
name: Verify build and test
34+
command: echo "Build and test completed successfully!"
2935
test-v12:
3036
docker:
3137
- image: cimg/base:stable
@@ -37,8 +43,11 @@ jobs:
3743
name: Run build
3844
command: npm install
3945
- run:
40-
name: Verify build
41-
command: echo "Build completed successfully!"
46+
name: Run test
47+
command: npm run test
48+
- run:
49+
name: Verify build and test
50+
command: echo "Build and test completed successfully!"
4251
test-v14:
4352
docker:
4453
- image: cimg/base:stable
@@ -50,8 +59,11 @@ jobs:
5059
name: Run build
5160
command: npm install
5261
- run:
53-
name: Verify build
54-
command: echo "Build completed successfully!"
62+
name: Run test
63+
command: npm run test
64+
- run:
65+
name: Verify build and test
66+
command: echo "Build and test completed successfully!"
5567
test-v16:
5668
docker:
5769
- image: cimg/base:stable
@@ -63,8 +75,11 @@ jobs:
6375
name: Run build
6476
command: npm install
6577
- run:
66-
name: Verify build
67-
command: echo "Build completed successfully!"
78+
name: Run test
79+
command: npm run test
80+
- run:
81+
name: Verify build and test
82+
command: echo "Build and test completed successfully!"
6883
test-v18:
6984
docker:
7085
- image: cimg/base:stable
@@ -76,37 +91,50 @@ jobs:
7691
name: Run build
7792
command: npm install
7893
- run:
79-
name: Verify build
80-
command: echo "Build completed successfully!"
94+
name: Run test
95+
command: npm run test
96+
- run:
97+
name: Verify build and test
98+
command: echo "Build and test completed successfully!"
8199
test-v20:
82100
docker:
83101
- image: cimg/base:stable
84102
steps:
85103
- checkout
86104
- node/install:
87-
node-version: "20.12"
105+
node-version: "20.18"
88106
- run:
89107
name: Run build
90108
command: npm install
91109
- run:
92-
name: Verify build
93-
command: echo "Build completed successfully!"
110+
name: Run test
111+
command: npm run test
112+
- run:
113+
name: Verify build and test
114+
command: echo "Build and test completed successfully!"
94115
test-v22:
95116
docker:
96117
- image: cimg/base:stable
97118
steps:
98119
- checkout
99120
- node/install:
100-
node-version: "22.0"
121+
node-version: "22.12"
101122
- run:
102123
name: Run build
103124
command: npm install
104125
- run:
105-
name: Verify build
106-
command: echo "Build completed successfully!"
126+
name: Run test
127+
command: npm run test
128+
- run:
129+
name: Verify build and test
130+
command: echo "Build and test completed successfully!"
107131
workflows:
108-
build:
132+
build_and_test:
109133
jobs:
134+
- test-v8
135+
- test-v10
136+
- test-v12
137+
- test-v14
110138
- test-v16
111139
- test-v18
112140
- test-v20

.github/workflows/node.js.yml

Lines changed: 8 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -7,38 +7,21 @@ on:
77
branches: [ "main", "dev" ]
88

99
jobs:
10-
test:
10+
build:
1111
runs-on: ubuntu-latest
1212
strategy:
1313
matrix:
14-
node-version: [16.x, 18.x, 20.x, 22.x]
14+
node-version: [8.x, 10.x, 12.x, 14.x, 16.x, 18.x, 20.x, 22.x]
1515

1616
steps:
1717
- uses: actions/checkout@v4
1818
- name: Use Node.js ${{ matrix.node-version }}
1919
uses: actions/setup-node@v4
2020
with:
2121
node-version: ${{ matrix.node-version }}
22-
- run: npm i
23-
- run: npm test
24-
env:
25-
SETS: set3
26-
27-
publish:
28-
runs-on: ubuntu-latest
29-
needs:
30-
- test
31-
steps:
32-
- uses: actions/checkout@v4
33-
- name: Install dependencies
34-
run: npm ci
35-
- name: Semantic Release
36-
uses: cycjimmy/semantic-release-action@v4
37-
env:
38-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
39-
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
40-
with:
41-
extra_plugins: |
42-
@semantic-release/changelog
43-
@semantic-release/git
44-
22+
- name: Run build
23+
run: npm isntall
24+
- name: Run test
25+
run: npm run test
26+
- name: Verify build and test
27+
run: echo "Build and test completed successfully!"

0 commit comments

Comments
 (0)