File: zsh5

package info (click to toggle)
zsh 5.3.1-4
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 16,324 kB
  • ctags: 8,554
  • sloc: ansic: 104,868; sh: 6,584; perl: 813; makefile: 774; awk: 388; sed: 16
file content (27 lines) | stat: -rw-r--r-- 843 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#!/bin/zsh -f

# This wrapper's sole purpose is to ease the migration of zsh's binary
# location from /bin/zsh5 to /bin/zsh between Debian Jessie and
# Stretch since zsh no more uses the alternatives system as there is
# only one version of zsh left in Debian since Jessie.
#
# Related bug report: https://bugs.debian.org/768079

if [[ "$0" == *zsh5* ]]; then
    static=''
    if [[ "$0" == *static* ]]; then
        static=-static
    fi

    echo ""
    echo "    ####"
    echo "    ####  $0 is deprecated, please switch to /bin/zsh${static} (or /usr/bin/zsh)"
    if [[ "$1" == "-l" || "$0" == -* ]]; then
        echo '    ####  Use "chsh -s '"/bin/zsh${static}"'" to change your login shell'
    fi
    echo "    ####  This command ($0) will disappear eventually!"
    echo "    ####"
    echo ""
fi 1>&2

exec "/bin/zsh${static}" "$@"