Skip to content

Commit ac1edc7

Browse files
authored
Prepare scoped Node package (#6386)
In case we're not able to get access to the unscoped credentials. Scoped packages are also the recommended approach for projects managed by a team of developers.
1 parent 7be9039 commit ac1edc7

File tree

3 files changed

+17
-2
lines changed

3 files changed

+17
-2
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@
5858
- CHANGED: Docker build, enabled arm64 build layer [#6172](https://github.com/Project-OSRM/osrm-backend/pull/6172)
5959
- CHANGED: Docker build, enabled apt-get update/install caching in separate layer for build phase [#6175](https://github.com/Project-OSRM/osrm-backend/pull/6175)
6060
- FIXED: Bump CI complete meta job to ubuntu-20.04 [#6323](https://github.com/Project-OSRM/osrm-backend/pull/6323)
61+
- CHANGED: Node packages are now scoped by @project-osrm [#6386](https://github.com/Project-OSRM/osrm-backend/issues/6386)
6162
- Routing:
6263
- CHANGED: Lazily generate optional route path data [#6045](https://github.com/Project-OSRM/osrm-backend/pull/6045)
6364
- FIXED: Completed support for no_entry and no_exit turn restrictions. [#5988](https://github.com/Project-OSRM/osrm-backend/pull/5988)

README.md

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ sudo apt-get update -y
141141
sudo apt-get install -y libstdc++-9-dev
142142
```
143143

144-
You can install the Node.js bindings via `npm install osrm` or from this repository either via
144+
You can install the Node.js bindings via `npm install @project-osrm/osrm` or from this repository either via
145145

146146
npm install
147147

@@ -151,6 +151,17 @@ which will check and use pre-built binaries if they're available for this releas
151151

152152
to always force building the Node.js bindings from source.
153153

154+
#### Unscoped packages
155+
156+
Prior to v5.27.0, the `osrm` Node package was unscoped. If you are upgrading from an old package, you will need to do the following:
157+
158+
```
159+
npm uninstall osrm --save
160+
npm install @project-osrm/osrm --save
161+
```
162+
163+
#### Package docs
164+
154165
For usage details have a look [these API docs](docs/nodejs/api.md).
155166

156167
An exemplary implementation by a 3rd party with Docker and Node.js can be found [here](https://github.com/door2door-io/osrm-express-server-demo).

package.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"name": "osrm",
2+
"name": "@project-osrm/osrm",
33
"version": "5.27.0-unreleased",
44
"private": false,
55
"description": "The Open Source Routing Machine is a high performance routing engine written in C++14 designed to run on OpenStreetMap data.",
@@ -81,5 +81,8 @@
8181
"host": "https://github.com",
8282
"remote_path": "./Project-OSRM/osrm-backend/releases/download/v{version}/",
8383
"package_name": "{module_name}-v{version}-{node_abi}-{platform}-{arch}-{configuration}.tar.gz"
84+
},
85+
"publishConfig": {
86+
"access": "public"
8487
}
8588
}

0 commit comments

Comments
 (0)