Skip to content

Commit 7f1c99d

Browse files
authored
Feat/publish private package (#2)
* feat: private nodejs package * temp: release package * temp: release package * temp: release package * temp: release package * fix: release package
1 parent 2d35281 commit 7f1c99d

4 files changed

Lines changed: 26 additions & 78 deletions

File tree

.github/workflows/publish-dry-run.yaml

Lines changed: 0 additions & 44 deletions
This file was deleted.

.github/workflows/publish.yaml

Lines changed: 21 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -2,43 +2,37 @@ name: publish
22

33
on:
44
workflow_dispatch:
5+
push:
6+
branches:
7+
- main
58

69
jobs:
7-
publish_crates_io:
8-
name: publish (crates.io)
9-
runs-on: ubuntu-latest
10-
11-
steps:
12-
- uses: actions/checkout@v4
13-
- uses: dtolnay/rust-toolchain@stable
14-
- name: apt-get install
15-
run: |
16-
sudo apt-get update
17-
sudo apt-get install -y libwebkit2gtk-4.1-dev
18-
- name: cargo publish
19-
run: cargo publish
20-
env:
21-
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}
22-
23-
publish_npmjs_com:
24-
name: publish (npmjs.com)
10+
publish_gh_packages:
11+
name: Publish to Github Packages
2512
runs-on: ubuntu-latest
2613
permissions:
27-
id-token: write # use of OIDC for npm provenance
28-
14+
contents: write
15+
packages: write
2916
steps:
30-
- uses: actions/checkout@v4
31-
- uses: pnpm/action-setup@v4
17+
- name: Checkout Repo
18+
uses: actions/checkout@v4
19+
20+
- name: pnpm setup
21+
uses: pnpm/action-setup@v4
3222
with:
3323
version: 9
34-
- uses: actions/setup-node@v4
24+
25+
- name: nodejs setup
26+
uses: actions/setup-node@v4
3527
with:
3628
node-version: "lts/*"
3729
registry-url: "https://registry.npmjs.org"
3830
cache: "pnpm"
39-
- run: pnpm install
31+
32+
- name: Install dependencies
33+
run: pnpm install --frozen-lockfile
34+
4035
- name: pnpm publish
41-
run: pnpm publish --access public --no-git-checks
36+
run: pnpm publish --access restricted --publish-branch main --tag next
4237
env:
43-
NPM_CONFIG_PROVENANCE: true
44-
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
38+
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.npmrc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
@metasig:registry=https://npm.pkg.github.com
2+
//npm.pkg.github.com/:_authToken=${NODE_AUTH_TOKEN}

package.json

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"name": "@impierce/tauri-plugin-keystore",
2+
"name": "@metasig/tauri-plugin-keystore",
33
"version": "2.1.0-alpha.1",
44
"author": "daniel-mader",
55
"description": "Interact with the device-native key storage (Android Keystore, iOS Keychain).",
@@ -33,10 +33,6 @@
3333
"license": "Apache-2.0",
3434
"repository": {
3535
"type": "git",
36-
"url": "git+https://github.com/impierce/tauri-plugin-keystore.git"
37-
},
38-
"bugs": {
39-
"url": "https://github.com/impierce/tauri-plugin-keystore/issues"
40-
},
41-
"homepage": "https://github.com/impierce/tauri-plugin-keystore#readme"
36+
"url": "git+https://github.com/Metasig/tauri-plugin-keystore.git"
37+
}
4238
}

0 commit comments

Comments
 (0)