Skip to content

Commit

Permalink
Update package version to 1.0.3, enhance CI/CD workflows, and refacto…
Browse files Browse the repository at this point in the history
…r 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.
  • Loading branch information
ROZ-MOFUMOFU-ME committed Dec 15, 2024
1 parent 2cef7cc commit 790103e
Show file tree
Hide file tree
Showing 7 changed files with 624 additions and 229 deletions.
66 changes: 47 additions & 19 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,11 @@ jobs:
name: Run build
command: npm install
- run:
name: Verify build
command: echo "Build completed successfully!"
name: Run test
command: npm run test
- run:
name: Verify build and test
command: echo "Build and test completed successfully!"
test-v10:
docker:
- image: cimg/base:stable
Expand All @@ -24,8 +27,11 @@ jobs:
name: Run build
command: npm install
- run:
name: Verify build
command: echo "Build completed successfully!"
name: Run test
command: npm run test
- run:
name: Verify build and test
command: echo "Build and test completed successfully!"
test-v12:
docker:
- image: cimg/base:stable
Expand All @@ -37,8 +43,11 @@ jobs:
name: Run build
command: npm install
- run:
name: Verify build
command: echo "Build completed successfully!"
name: Run test
command: npm run test
- run:
name: Verify build and test
command: echo "Build and test completed successfully!"
test-v14:
docker:
- image: cimg/base:stable
Expand All @@ -50,8 +59,11 @@ jobs:
name: Run build
command: npm install
- run:
name: Verify build
command: echo "Build completed successfully!"
name: Run test
command: npm run test
- run:
name: Verify build and test
command: echo "Build and test completed successfully!"
test-v16:
docker:
- image: cimg/base:stable
Expand All @@ -63,8 +75,11 @@ jobs:
name: Run build
command: npm install
- run:
name: Verify build
command: echo "Build completed successfully!"
name: Run test
command: npm run test
- run:
name: Verify build and test
command: echo "Build and test completed successfully!"
test-v18:
docker:
- image: cimg/base:stable
Expand All @@ -76,37 +91,50 @@ jobs:
name: Run build
command: npm install
- run:
name: Verify build
command: echo "Build completed successfully!"
name: Run test
command: npm run test
- run:
name: Verify build and test
command: echo "Build and test completed successfully!"
test-v20:
docker:
- image: cimg/base:stable
steps:
- checkout
- node/install:
node-version: "20.12"
node-version: "20.18"
- run:
name: Run build
command: npm install
- run:
name: Verify build
command: echo "Build completed successfully!"
name: Run test
command: npm run test
- run:
name: Verify build and test
command: echo "Build and test completed successfully!"
test-v22:
docker:
- image: cimg/base:stable
steps:
- checkout
- node/install:
node-version: "22.0"
node-version: "22.12"
- run:
name: Run build
command: npm install
- run:
name: Verify build
command: echo "Build completed successfully!"
name: Run test
command: npm run test
- run:
name: Verify build and test
command: echo "Build and test completed successfully!"
workflows:
build:
build_and_test:
jobs:
- test-v8
- test-v10
- test-v12
- test-v14
- test-v16
- test-v18
- test-v20
Expand Down
33 changes: 8 additions & 25 deletions .github/workflows/node.js.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,38 +7,21 @@ on:
branches: [ "main", "dev" ]

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

steps:
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- run: npm i
- run: npm test
env:
SETS: set3

publish:
runs-on: ubuntu-latest
needs:
- test
steps:
- uses: actions/checkout@v4
- name: Install dependencies
run: npm ci
- name: Semantic Release
uses: cycjimmy/semantic-release-action@v4
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
with:
extra_plugins: |
@semantic-release/changelog
@semantic-release/git
- name: Run build
run: npm isntall
- name: Run test
run: npm run test
- name: Verify build and test
run: echo "Build and test completed successfully!"
Loading

0 comments on commit 790103e

Please sign in to comment.