Skip to content

Commit 9385adf

Browse files
committed
Switch to npm
1 parent c15603a commit 9385adf

4 files changed

Lines changed: 11 additions & 13 deletions

File tree

.github/workflows/publish.yml

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
name: Publish package to GitHub Packages
2-
on:
3-
push:
4-
branches: [ main ]
2+
on: push #branches: [ main ]
53
jobs:
64
build:
75
defaults:
@@ -10,15 +8,15 @@ jobs:
108
runs-on: ubuntu-latest
119
permissions:
1210
contents: read
13-
packages: write
11+
id-token: write
1412
steps:
1513
- uses: actions/checkout@v4
14+
# Setup .npmrc file to publish to npm
1615
- uses: actions/setup-node@v4
1716
with:
1817
node-version: '20.x'
19-
registry-url: 'https://npm.pkg.github.com'
20-
scope: '@register-dynamics'
18+
registry-url: 'https://registry.npmjs.org'
2119
- run: npm ci
22-
- run: npm publish
20+
- run: npm publish --provenance --access public
2321
env:
24-
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
22+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

lib/importer/.npmrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
@register-dynamics:registry=https://npm.pkg.github.com
1+
@register-dynamics:registry=https://registry.npmjs.org

lib/importer/package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/importer/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
{
22
"name": "@register-dynamics/importer",
3-
"version": "0.1.2",
3+
"version": "0.1.1",
44
"repository": {
55
"type": "git",
66
"url": "https://github.com/register-dynamics/data-import.git",
77
"directory": "lib/importer"
88
},
99
"owner": "register-dynamics",
1010
"publishConfig": {
11-
"registry": "https://npm.pkg.github.com"
11+
"registry": "https://registry.npmjs.org"
1212
},
1313
"main": "src/index.js",
1414
"scripts": {

0 commit comments

Comments
 (0)