Skip to content

Commit 4b80a96

Browse files
committed
Update README
1 parent 2da037e commit 4b80a96

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

README.md

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,22 @@
22

33
Use e.g. in a `package.json` or github action
44

5+
### In your package.json
56
```json
67
{
78
"scripts": {
89
"prepublishOnly": "npx --yes needle-tools/npm-publish-helper",
9-
"compile": "npx --yes needle-tools/npm-publish-helper compile"
10+
"compile": "npx --yes needle-tools/npm-publish-helper compile",
1011
},
1112
}
1213
```
1314

15+
### Publish via github workflow
16+
```yml
17+
- name: Run publish command # publish a new version with a tag + git short hash
18+
run: npx . publish "path/to/directory" --webhook "${{ secrets.DISCORD_WEBHOOK }}" --access-token "${{ secrets.NPM_TOKEN }}" --version+hash --version+tag --tag --tag "${{ github.ref_name }}"
19+
```
20+
1421
1522
1623
# Contact ✒️

0 commit comments

Comments
 (0)