Skip to content

Commit 9623a3c

Browse files
committed
build: update publish script
1 parent 76b1c41 commit 9623a3c

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

publish.sh

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ else
5252
exit -1
5353
fi
5454

55-
# run wasm-pack
55+
# run wasm-pack to see if there is any bugs
5656
if wasm-pack build float-pigment-css --target nodejs --features nodejs-package; then
5757
echo 'WebAssembly built for float-pigment-css.'
5858
else
@@ -114,6 +114,14 @@ else
114114
exit -1
115115
fi
116116

117+
# run wasm-pack again to update package version
118+
if wasm-pack build float-pigment-css --target nodejs --features nodejs-package; then
119+
echo 'WebAssembly built for float-pigment-css.'
120+
else
121+
echo 'Failed to build WebAssembly package for float-pigment-css! Abort.'
122+
exit -1
123+
fi
124+
117125
# cargo publish
118126
echo "Ready to publish version ${VERSION}."
119127
for PROJECT in $PROJECTS; do

0 commit comments

Comments
 (0)