bmssp 0.5.0 → 0.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.editorconfig +7 -0
- package/.github/workflows/{dockerhub.yml → dockerhub-build-publish.yml} +8 -6
- package/.github/workflows/npm-build.yml +34 -0
- package/.github/workflows/npm-publish.yml +37 -0
- package/Dockerfile +1 -1
- package/docs/index.html +2 -2
- package/package.json +2 -2
- package/src/bmssp.mjs +1 -1
- package/{tests → test}/main.js +1 -1
- package/.github/workflows/npmjs.yml +0 -24
package/.editorconfig
ADDED
|
@@ -1,17 +1,19 @@
|
|
|
1
1
|
name: Build and publish Docker image
|
|
2
2
|
|
|
3
3
|
on:
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
- '*.*.*'
|
|
4
|
+
release:
|
|
5
|
+
types: [published]
|
|
7
6
|
|
|
8
7
|
jobs:
|
|
9
8
|
docker-build-and-publish:
|
|
10
9
|
environment:
|
|
11
10
|
name: dockerhub
|
|
11
|
+
|
|
12
|
+
runs-on: ubuntu-latest
|
|
13
|
+
|
|
12
14
|
permissions:
|
|
13
15
|
contents: read
|
|
14
|
-
|
|
16
|
+
|
|
15
17
|
steps:
|
|
16
18
|
- name: Docker meta
|
|
17
19
|
id: meta
|
|
@@ -25,7 +27,7 @@ jobs:
|
|
|
25
27
|
type=semver,pattern={{version}}
|
|
26
28
|
type=semver,pattern={{major}}.{{minor}}
|
|
27
29
|
type=semver,pattern={{major}}
|
|
28
|
-
- name: Checkout
|
|
30
|
+
- name: Checkout code
|
|
29
31
|
uses: actions/checkout@v5
|
|
30
32
|
|
|
31
33
|
- name: Login to Docker Hub
|
|
@@ -46,4 +48,4 @@ jobs:
|
|
|
46
48
|
context: .
|
|
47
49
|
platforms: linux/amd64,linux/arm64
|
|
48
50
|
push: true
|
|
49
|
-
tags: ${{ steps.meta.outputs.tags }}
|
|
51
|
+
tags: ${{ steps.meta.outputs.tags }}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
name: Build npm package
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
pull_request:
|
|
5
|
+
branches: [main]
|
|
6
|
+
push:
|
|
7
|
+
branches: [main]
|
|
8
|
+
|
|
9
|
+
jobs:
|
|
10
|
+
npm-build:
|
|
11
|
+
runs-on: ubuntu-latest
|
|
12
|
+
|
|
13
|
+
permissions:
|
|
14
|
+
contents: read
|
|
15
|
+
|
|
16
|
+
strategy:
|
|
17
|
+
matrix:
|
|
18
|
+
node-version: [24.x]
|
|
19
|
+
|
|
20
|
+
steps:
|
|
21
|
+
- name: Checkout code
|
|
22
|
+
uses: actions/checkout@v5
|
|
23
|
+
|
|
24
|
+
- name: Setup Node.js ${{ matrix.node-version }}
|
|
25
|
+
uses: actions/setup-node@v4
|
|
26
|
+
with:
|
|
27
|
+
node-version: ${{ matrix.node-version }}
|
|
28
|
+
cache: 'npm'
|
|
29
|
+
|
|
30
|
+
- name: Install dependencies
|
|
31
|
+
run: npm ci
|
|
32
|
+
|
|
33
|
+
- name: Run tests
|
|
34
|
+
run: npm test
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
name: Publish npm package
|
|
2
|
+
on:
|
|
3
|
+
release:
|
|
4
|
+
types: [published]
|
|
5
|
+
jobs:
|
|
6
|
+
npm-publish:
|
|
7
|
+
environment:
|
|
8
|
+
name: npm-bmssp
|
|
9
|
+
|
|
10
|
+
runs-on: ubuntu-latest
|
|
11
|
+
|
|
12
|
+
strategy:
|
|
13
|
+
matrix:
|
|
14
|
+
node-version: [24.x]
|
|
15
|
+
|
|
16
|
+
permissions:
|
|
17
|
+
contents: read
|
|
18
|
+
id-token: write
|
|
19
|
+
|
|
20
|
+
steps:
|
|
21
|
+
- name: Checkout code
|
|
22
|
+
uses: actions/checkout@v5
|
|
23
|
+
|
|
24
|
+
- name: Setup Node.js ${{ matrix.node-version }}
|
|
25
|
+
uses: actions/setup-node@v4
|
|
26
|
+
with:
|
|
27
|
+
node-version: ${{ matrix.node-version }}
|
|
28
|
+
cache: 'npm'
|
|
29
|
+
registry-url: 'https://registry.npmjs.org'
|
|
30
|
+
|
|
31
|
+
- name: Install dependencies
|
|
32
|
+
run: npm ci
|
|
33
|
+
|
|
34
|
+
- name: Publish package
|
|
35
|
+
run: npm publish --provenance --access public
|
|
36
|
+
env:
|
|
37
|
+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|
package/Dockerfile
CHANGED
package/docs/index.html
CHANGED
|
@@ -72,7 +72,7 @@
|
|
|
72
72
|
Implementation of the Single Source Shortest Path (SSSP) algorithm - Bounded Multiple Source Shortest Paths (BMSSP), originally published by Tsinghua University's research.
|
|
73
73
|
</p>
|
|
74
74
|
<p>
|
|
75
|
-
Read the original paper:
|
|
75
|
+
Read the original paper:
|
|
76
76
|
<a href="https://dl.acm.org/doi/10.1145/3717823.3718179" target="_blank">
|
|
77
77
|
Tsinghua SSSP Paper
|
|
78
78
|
</a>
|
|
@@ -93,4 +93,4 @@
|
|
|
93
93
|
<a class="btn" href="https://github.com/sirivasv/tsinghua-sssp" target="_blank">View on GitHub</a>
|
|
94
94
|
</div>
|
|
95
95
|
</body>
|
|
96
|
-
</html></svg>
|
|
96
|
+
</html></svg>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "bmssp",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.6.0",
|
|
4
4
|
"description": "Javascript package implementation of the bmssp algorithm.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"shortest-paths",
|
|
@@ -24,6 +24,6 @@
|
|
|
24
24
|
"doc": "docs"
|
|
25
25
|
},
|
|
26
26
|
"scripts": {
|
|
27
|
-
"test": "node
|
|
27
|
+
"test": "node test/main.js"
|
|
28
28
|
}
|
|
29
29
|
}
|
package/src/bmssp.mjs
CHANGED
package/{tests → test}/main.js
RENAMED
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
name: Publish Package to npmjs
|
|
2
|
-
on:
|
|
3
|
-
release:
|
|
4
|
-
types: [published]
|
|
5
|
-
jobs:
|
|
6
|
-
build-and-publish:
|
|
7
|
-
environment:
|
|
8
|
-
name: npm-bmssp
|
|
9
|
-
runs-on: ubuntu-latest
|
|
10
|
-
permissions:
|
|
11
|
-
contents: read
|
|
12
|
-
id-token: write
|
|
13
|
-
steps:
|
|
14
|
-
- uses: actions/checkout@v5
|
|
15
|
-
# Setup .npmrc file to publish to npm
|
|
16
|
-
- uses: actions/setup-node@v4
|
|
17
|
-
with:
|
|
18
|
-
node-version: '24.x'
|
|
19
|
-
registry-url: 'https://registry.npmjs.org'
|
|
20
|
-
- run: npm test
|
|
21
|
-
- run: npm ci
|
|
22
|
-
- run: npm publish --provenance --access public
|
|
23
|
-
env:
|
|
24
|
-
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|