Skip to content

Commit 950d5b4

Browse files
committed
update-to-head: whole relocate hint as a here script
1 parent 46c62dc commit 950d5b4

File tree

1 file changed

+15
-14
lines changed

1 file changed

+15
-14
lines changed

update-to-head.sh

Lines changed: 15 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -83,21 +83,22 @@ rm -f "$HOME/.pyroscope/rtorrent.d"/view-zz-collapse.rc* 2>/dev/null || :
8383
./bin/pyroadmin --create-config
8484
./bin/pyroadmin --create-import "~/.pyroscope/rtorrent.d/*.rc.default"
8585

86-
# Relocate to ~/.local?
87-
if test "$PROJECT_ROOT" = "$HOME/lib/pyroscope"; then
88-
echo
89-
echo "*****************************************************************************"
90-
echo "The default install location has changed, consider moving to the new path"
91-
echo "at '~/.local/pyroscope'!"
92-
echo
93-
cat <<'EOF'
94-
mkdir -p ~/.local/pyroscope
95-
cp -p ~/lib/pyroscope/update-to-head.sh ~/.local/pyroscope
96-
~/.local/pyroscope/update-to-head.sh
86+
# Relocate to ~/.local
87+
test "$PROJECT_ROOT" != "$HOME/lib/pyroscope" || cat <<'EOF'
88+
89+
*****************************************************************************
90+
The default install location has changed, consider moving to the new path at
91+
'~/.local/pyroscope'!
92+
93+
Call these commands:
94+
95+
mkdir -p ~/.local/pyroscope
96+
cp -p ~/lib/pyroscope/update-to-head.sh ~/.local/pyroscope
97+
~/.local/pyroscope/update-to-head.sh
98+
99+
*****************************************************************************
100+
97101
EOF
98-
echo "*****************************************************************************"
99-
echo
100-
fi
101102

102103
# Make sure PATH is decent
103104
( echo $PATH | tr : \\n | egrep "^$HOME/bin/?\$" >/dev/null ) || echo "$HOME/bin is NOT on your PATH, you need to fix that"'!'

0 commit comments

Comments
 (0)