File tree Expand file tree Collapse file tree 1 file changed +31
-0
lines changed
Expand file tree Collapse file tree 1 file changed +31
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Publish package to NPM
2+
3+ on :
4+ push :
5+ branches :
6+ - master
7+
8+ jobs :
9+ publish :
10+ runs-on : ubuntu-latest
11+ steps :
12+ - uses : actions/checkout@v2
13+ - uses : actions/setup-node@v1
14+ with :
15+ node-version : 12
16+ registry-url : https://registry.npmjs.org/
17+ - run : yarn
18+ - run : yarn build
19+ - run : yarn publish --access=public
20+ env :
21+ NODE_AUTH_TOKEN : ${{ secrets.NPM_TOKEN }}
22+ notify :
23+ needs : publish
24+ runs-on : ubuntu-latest
25+ steps :
26+ - uses : actions/checkout@v2
27+ - run : echo ::set-env name=EMOJI_PACKAGE::$'\xf0\x9f\x93\xa6'
28+ - run : echo ::set-env name=PACKAGE_NAME::$(node -p "require('./package.json').name")
29+ - run : echo ::set-env name=PACKAGE_VERSION::$(node -p "require('./package.json').version")
30+ - run : echo ::set-env name=MESSAGE::"$EMOJI_PACKAGE [$PACKAGE_NAME](https://npmjs.com/package/$PACKAGE_NAME) $PACKAGE_VERSION was published"
31+ - run : curl -X POST ${{ secrets.CODEX_BOT_NOTIFY_EDITORJS_PUBLIC_CHAT }} -d "message=$MESSAGE" -d parse_mode=Markdown -d disable_web_page_preview=true
You can’t perform that action at this time.
0 commit comments