Skip to content

Commit f88b1a6

Browse files
committed
fixup: move after release dir created
1 parent cac1114 commit f88b1a6

File tree

1 file changed

+13
-12
lines changed

1 file changed

+13
-12
lines changed

ci/steps/publish-npm.sh

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -60,18 +60,6 @@ main() {
6060
exit 1
6161
fi
6262

63-
# NOTE@jsjoeio - this needs to run inside the release dir
64-
# where the package.json for code-server is.
65-
pushd release
66-
if npm pkg get name && [ $? -eq 1 ]; then
67-
echo "Couldn't get package.json name with 'npm pkg get name'"
68-
echo "This usually means npm v7 or higher could not be found."
69-
echo "We use this to modify the package.json name for dev builds."
70-
echo "Please upgrade to npm v7 or higher and re-run the script."
71-
exit 1
72-
fi
73-
popd
74-
7563
# This allows us to publish to npm in CI workflows
7664
if [[ ${CI-} ]]; then
7765
echo "//registry.npmjs.org/:_authToken=${NPM_TOKEN}" > ~/.npmrc
@@ -106,6 +94,19 @@ main() {
10694
# Ignore symlink when publishing npm package
10795
# See: https://github.com/coder/code-server/pull/3935
10896
echo "node_modules.asar" > release/.npmignore
97+
98+
# NOTE@jsjoeio - this needs to run inside the release dir
99+
# where the package.json for code-server is.
100+
pushd release
101+
if npm pkg get name && [ $? -eq 1 ]; then
102+
echo "Couldn't get package.json name with 'npm pkg get name'"
103+
echo "This usually means npm v7 or higher could not be found."
104+
echo "We use this to modify the package.json name for dev builds."
105+
echo "Please upgrade to npm v7 or higher and re-run the script."
106+
exit 1
107+
fi
108+
popd
109+
109110
# We use this to set the name of the package in the
110111
# package.json
111112
PACKAGE_NAME="code-server"

0 commit comments

Comments
 (0)