Skip to content

Commit 87f738e

Browse files
committed
ci: publish package to GitHub Packages and npmjs.org
1 parent d18f400 commit 87f738e

File tree

2 files changed

+18
-2
lines changed

2 files changed

+18
-2
lines changed

.github/workflows/release.yml

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,20 @@ jobs:
101101
node-version: "18"
102102
registry-url: "https://registry.npmjs.org"
103103

104-
- name: Publish to NPM
104+
- name: Set scope for GitHub
105+
run: |
106+
jq '.name = "@robert27/expo-github-cache"' package.json > tmp.json && mv tmp.json package.json
107+
108+
- name: Publish to GitHub Packages
109+
run: npm publish --registry=https://npm.pkg.github.com
110+
env:
111+
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
112+
113+
- name: Set scope for npmjs
114+
run: |
115+
jq '.name = "@eggl-js/expo-github-cache"' package.json > tmp.json && mv tmp.json package.json
116+
117+
- name: Publish to npmjs.org
105118
run: npm publish
106119
env:
107120
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

package.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
"name": "@eggl-js/expo-github-cache",
33
"version": "0.1.1",
44
"license": "MIT",
5+
"description": "A Expo build cache using GitHub as a storage backend.",
6+
"keywords": ["expo", "cache", "github", "build", "eas"],
57
"main": "build/index.js",
68
"types": "build/index.d.ts",
79
"repository": {
@@ -10,7 +12,8 @@
1012
},
1113
"files": ["/build"],
1214
"publishConfig": {
13-
"access": "public"
15+
"access": "public",
16+
"registry": "https://npm.pkg.github.com"
1417
},
1518
"scripts": {
1619
"lint": "biome check",

0 commit comments

Comments
 (0)