mirror of
https://github.com/kovidgoyal/kitty
synced 2026-06-06 01:05:48 +02:00
@@ -240,6 +240,12 @@ exec_login_shell() {
|
||||
execute_with_perl
|
||||
execute_sh_with_posix_env
|
||||
exec "$login_shell" "-l"
|
||||
printf "%s\n" "Could not execute the shell $login_shell as a login shell" > /dev/stderr
|
||||
if [ -e /dev/stderr ]; then
|
||||
printf "%s\n" "Could not execute the shell $login_shell as a login shell" > /dev/stderr
|
||||
elif [ -e /dev/fd/2 ]; then
|
||||
printf "%s\n" "Could not execute the shell $login_shell as a login shell" > /dev/fd/2
|
||||
else
|
||||
printf "%s\n" "Could not execute the shell $login_shell as a login shell"
|
||||
fi
|
||||
exec "$login_shell"
|
||||
}
|
||||
|
||||
@@ -14,7 +14,17 @@ cleanup_on_bootstrap_exit() {
|
||||
tdir=""
|
||||
}
|
||||
|
||||
die() { printf "\033[31m%s\033[m\n\r" "$*" > /dev/stderr; cleanup_on_bootstrap_exit; exit 1; }
|
||||
die() {
|
||||
if [ -e /dev/stderr ]; then
|
||||
printf "\033[31m%s\033[m\n\r" "$*" > /dev/stderr;
|
||||
elif [ -e /dev/fd/2 ]; then
|
||||
printf "\033[31m%s\033[m\n\r" "$*" > /dev/fd/2;
|
||||
else
|
||||
printf "\033[31m%s\033[m\n\r" "$*";
|
||||
fi
|
||||
cleanup_on_bootstrap_exit;
|
||||
exit 1;
|
||||
}
|
||||
|
||||
python_detected="0"
|
||||
detect_python() {
|
||||
|
||||
@@ -6,7 +6,16 @@
|
||||
{ \unalias command; \unset -f command; } >/dev/null 2>&1
|
||||
|
||||
|
||||
die() { printf "\033[31m%s\033[m\n\r" "$*" > /dev/stderr; exit 1; }
|
||||
die() {
|
||||
if [ -e /dev/stderr ]; then
|
||||
printf "\033[31m%s\033[m\n\r" "$*" > /dev/stderr;
|
||||
elif [ -e /dev/fd/2 ]; then
|
||||
printf "\033[31m%s\033[m\n\r" "$*" > /dev/fd/2;
|
||||
else
|
||||
printf "\033[31m%s\033[m\n\r" "$*";
|
||||
fi
|
||||
exit 1;
|
||||
}
|
||||
|
||||
exec_kitty() {
|
||||
[ -n "$kitty_exe" ] && exec "$kitty_exe" "$@"
|
||||
|
||||
Reference in New Issue
Block a user