Files
zulip/web/shared/tools/npm-postversion
Anders Kaseorg c1675913a2 web: Move web app to ‘web’ directory.
Ever since we started bundling the app with webpack, there’s been less
and less overlap between our ‘static’ directory (files belonging to
the frontend app) and Django’s interpretation of the ‘static’
directory (files served directly to the web).

Split the app out to its own ‘web’ directory outside of ‘static’, and
remove all the custom collectstatic --ignore rules.  This makes it
much clearer what’s actually being served to the web, and what’s being
bundled by webpack.  It also shrinks the release tarball by 3%.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
2023-02-23 16:04:17 -08:00

30 lines
604 B
Bash
Executable File

#!/usr/bin/env bash
set -eu -o pipefail
# expect this to run as NPM script
: "${npm_package_version?}"
should_color=
if [ -t 2 ]; then # if we're sending to a terminal
should_color=yes
fi
reset=
bold=
if [ -n "${should_color}" ]; then
reset=$'\033'[0m
bold=$'\033'[1m
fi
echo >&2 "\
Version updated: ${bold}${npm_package_version}${reset}
Next steps:
\$ ${bold}git log --stat -p upstream..${reset} # check your work!
\$ ${bold}git push --atomic upstream main shared-${npm_package_version}${reset}
\$ ${bold}npm publish${reset} # should prompt for an OTP, from your 2FA setup
"