install.sh: Improvements

This commit is contained in:
Anmol Sethi 2022-12-06 07:54:14 -08:00
parent 5ee11417e4
commit 3478ffbc5a
No known key found for this signature in database
GPG key ID: 25BC68888A99A8BA
4 changed files with 9 additions and 45 deletions

View file

@ -207,16 +207,12 @@ main() {
if [ -n "${UNINSTALL-}" ]; then
uninstall
if [ -n "${DRY_RUN-}" ]; then
bigheader "***********
Rerun without --dry-run to execute printed commands and perform install.
***********"
bigheader "Rerun without --dry-run to execute printed commands and perform install."
fi
else
install
if [ -n "${DRY_RUN-}" ]; then
bigheader "***********
Rerun without --dry-run to execute printed commands and perform install.
***********"
bigheader "Rerun without --dry-run to execute printed commands and perform install."
fi
fi
}
@ -277,13 +273,6 @@ EOF
log "Run man d2plugin-tala for detailed TALA docs."
fi
fi
logcat >&2 <<EOF
Something not working? Please let us know:
https://github.com/terrastruct/d2/issues
https://github.com/terrastruct/d2/discussions
https://discord.gg/NF6X8K4eDq
EOF
}
install_post_brew() {
@ -298,13 +287,6 @@ install_post_brew() {
if [ -n "${TALA-}" ]; then
log "Run man d2plugin-tala for detailed TALA docs."
fi
logcat >&2 <<EOF
Something not working? Please let us know:
https://github.com/terrastruct/d2/issues
https://github.com/terrastruct/d2/discussions
https://discord.gg/NF6X8K4eDq
EOF
VERSION=$(brew info d2 | head -n1 | cut -d' ' -f4)
VERSION=${VERSION%,}

View file

@ -273,9 +273,9 @@ header() {
bigheader() {
set -- "$(echo "$*" | sed "s/^/ * /")"
FGCOLOR=${FGCOLOR:-5} logp "/**
FGCOLOR=${FGCOLOR:-3} logp "/****************************************************************
$*
**/"
****************************************************************/"
}
# humanpath replaces all occurrences of " $HOME" with " ~"

2
ci/sub

@ -1 +1 @@
Subproject commit a3961af4299a6b9e642ebce305609f091eb7e88d
Subproject commit 718a738a16a9de19ec8d5f9654a9bb94546d8898

View file

@ -278,9 +278,9 @@ header() {
bigheader() {
set -- "$(echo "$*" | sed "s/^/ * /")"
FGCOLOR=${FGCOLOR:-5} logp "/**
FGCOLOR=${FGCOLOR:-3} logp "/****************************************************************
$*
**/"
****************************************************************/"
}
# humanpath replaces all occurrences of " $HOME" with " ~"
@ -790,16 +790,12 @@ main() {
if [ -n "${UNINSTALL-}" ]; then
uninstall
if [ -n "${DRY_RUN-}" ]; then
bigheader "***********
Rerun without --dry-run to execute printed commands and perform install.
***********"
bigheader "Rerun without --dry-run to execute printed commands and perform install."
fi
else
install
if [ -n "${DRY_RUN-}" ]; then
bigheader "***********
Rerun without --dry-run to execute printed commands and perform install.
***********"
bigheader "Rerun without --dry-run to execute printed commands and perform install."
fi
fi
}
@ -860,13 +856,6 @@ EOF
log "Run man d2plugin-tala for detailed TALA docs."
fi
fi
logcat >&2 <<EOF
Something not working? Please let us know:
https://github.com/terrastruct/d2/issues
https://github.com/terrastruct/d2/discussions
https://discord.gg/NF6X8K4eDq
EOF
}
install_post_brew() {
@ -881,13 +870,6 @@ install_post_brew() {
if [ -n "${TALA-}" ]; then
log "Run man d2plugin-tala for detailed TALA docs."
fi
logcat >&2 <<EOF
Something not working? Please let us know:
https://github.com/terrastruct/d2/issues
https://github.com/terrastruct/d2/discussions
https://discord.gg/NF6X8K4eDq
EOF
VERSION=$(brew info d2 | head -n1 | cut -d' ' -f4)
VERSION=${VERSION%,}