File tree Expand file tree Collapse file tree 1 file changed +34
-4
lines changed
Expand file tree Collapse file tree 1 file changed +34
-4
lines changed Original file line number Diff line number Diff line change 11name : Build And Release
22
3- on : [workflow_dispatch, push]
3+ on :
4+ workflow_dispatch :
5+ push :
6+ tags :
7+ - ' v*'
8+ branches :
9+ - main
410
511jobs :
612 Build :
7581 with :
7682 submodules : true
7783
84+ - name : Update npm
85+ run : npm install -g npm@latest
86+
87+ - name : Install pnpm
88+ uses : pnpm/action-setup@v4
89+
7890 - name : Download Artifacts
7991 uses : actions/download-artifact@v3
8092
8597 rm -rf bin-*
8698 sudo chmod -R +x bin
8799
100+ - name : Verify Binaries
101+ run : |
102+ // make sure all binaries are present
103+ if [ ! -f bin/dump-syms-linux-x64 ]; then echo "Missing bin/dump-syms-linux-x64" && exit 1; fi
104+ if [ ! -f bin/dump-syms-linux-arm64 ]; then echo "Missing bin/dump-syms-linux-arm64" && exit 1; fi
105+ if [ ! -f bin/dump-syms-macos-x64 ]; then echo "Missing bin/dump-syms-macos-x64" && exit 1; fi
106+ if [ ! -f bin/dump-syms-macos-arm64 ]; then echo "Missing bin/dump-syms-macos-arm64" && exit 1; fi
107+ if [ ! -f bin/dump-syms-windows-x64.exe ]; then echo "Missing bin/dump-syms-windows-x64.exe" && exit 1; fi
108+ if [ ! -f bin/dump-syms-windows-arm64.exe ]; then echo "Missing bin/dump-syms-windows-arm64.exe" && exit 1; fi
109+
110+ - name : Verify Version
111+ run : |
112+ TAG_VERSION=${GITHUB_REF#refs/tags/v}
113+ PACKAGE_VERSION=$(node -p "require('./package.json').version")
114+ if [ "$TAG_VERSION" != "$PACKAGE_VERSION" ]; then
115+ echo "Tag version ($TAG_VERSION) does not match package.json version ($PACKAGE_VERSION)"
116+ exit 1
117+ fi
118+
88119 # this will only publish if the version has been updated
89120 - name : NPM Publish
90- uses :
JS-DevTools/[email protected] 91- with :
92- token : ${{secrets.NPM_TOKEN}}
121+ run : |
122+ npm publish
You can’t perform that action at this time.
0 commit comments