Thanks to visit codestin.com
Credit goes to github.com

Skip to content

fix: clarify wording of install.sh --dry-run output #2751

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 30, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 24 additions & 0 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,11 @@ echo_latest_version() {
}

echo_standalone_postinstall() {
if [ "${DRY_RUN-}" ]; then
echo_dryrun_postinstall
return
fi

cath <<EOF

Standalone release has been installed into $STANDALONE_INSTALL_PREFIX/bin/$STANDALONE_BINARY_NAME
Expand All @@ -105,6 +110,11 @@ EOF
}

echo_systemd_postinstall() {
if [ "${DRY_RUN-}" ]; then
echo_dryrun_postinstall
return
fi

echoh
cath <<EOF
$1 package has been installed.
Expand All @@ -125,6 +135,15 @@ Or, just run the server directly:
EOF
}

echo_dryrun_postinstall() {
cath <<EOF

Dry-run complete.

To install Coder, re-run this script without the --dry-run flag.
EOF
}

main() {
if [ "${TRACE-}" ]; then
set -x
Expand Down Expand Up @@ -241,6 +260,11 @@ main() {

distro_name

if [ "${DRY_RUN-}" ]; then
echoh "Running with --dry-run; the following are the commands that would be run if this were a real installation:"
echoh
fi

# Standalone installs by pulling pre-built releases from GitHub.
if [ "$METHOD" = standalone ]; then
if has_standalone; then
Expand Down