Skip to content

Commit b75f1eb

Browse files
committed
Replace GitHub with npm links in publish script
1 parent 7635741 commit b75f1eb

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

lib/node_modules/@stdlib/_tools/scripts/templates/workflow_publish.yml.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,11 +38,17 @@ jobs:
3838
git config --local user.email "noreply@stdlib.io"
3939
git config --local user.name "stdlib-bot"
4040
npm version patch
41+
- name: Replace all GitHub links to individual packages with npm links
42+
run: |
43+
find . -type f -name '*.md' -print0 | xargs -0 sed -Ei 's/@stdlib\/([^:]*)\]: https:\/\/github.com\/stdlib-js/@stdlib\/\1\]: https:\/\/www.npmjs.com\/package\/@stdlib/g'
4144
- name: Publish package to npm
4245
uses: JS-DevTools/npm-publish@v1
4346
with:
4447
token: ${{ secrets.NPM_TOKEN }}
4548
access: public
49+
- name: Discard any uncommitted changes
50+
run: |
51+
git reset --hard
4652
- name: Push changes
4753
run: |
4854
git push origin main

0 commit comments

Comments
 (0)