2005-09-20 21:31:55 +08:00
|
|
|
#
|
|
|
|
# Init file for fish
|
|
|
|
#
|
|
|
|
|
2006-03-10 21:40:39 +08:00
|
|
|
#
|
2006-03-14 08:09:14 +08:00
|
|
|
# Some things should only be done for login terminals
|
2006-03-10 21:40:39 +08:00
|
|
|
#
|
|
|
|
|
|
|
|
if status --is-login
|
2006-03-14 08:09:14 +08:00
|
|
|
|
|
|
|
#
|
|
|
|
# Set some value for LANG if nothing was set before, and this is a
|
|
|
|
# login shell.
|
|
|
|
#
|
|
|
|
|
2006-03-10 21:40:39 +08:00
|
|
|
if not set -q LANG >/dev/null
|
|
|
|
set -gx LANG en_US.UTF-8
|
|
|
|
end
|
|
|
|
|
2006-03-14 08:09:14 +08:00
|
|
|
# Check for i18n information in
|
|
|
|
# /etc/sysconfig/i18n
|
|
|
|
|
2006-03-10 21:40:39 +08:00
|
|
|
if test -f /etc/sysconfig/i18n
|
|
|
|
eval (cat /etc/sysconfig/i18n |sed -ne 's/^\([a-zA-Z]*\)=\(.*\)$/set -gx \1 \2;/p')
|
|
|
|
end
|
|
|
|
|
2006-03-14 08:09:14 +08:00
|
|
|
#
|
|
|
|
# Put linux consoles in unicode mode.
|
|
|
|
#
|
2005-09-20 21:31:55 +08:00
|
|
|
|
2006-03-14 08:09:14 +08:00
|
|
|
if expr "$LANG" : ".*\.[Uu][Tt][Ff].*" >/dev/null
|
|
|
|
if test "$TERM" = linux
|
|
|
|
if which unicode_start >/dev/null
|
|
|
|
unicode_start
|
|
|
|
end
|
2006-03-10 21:51:29 +08:00
|
|
|
end
|
2005-09-20 21:31:55 +08:00
|
|
|
end
|
|
|
|
end
|
|
|
|
|
2005-09-26 20:33:06 +08:00
|
|
|
#
|
|
|
|
# Load additional initialization files
|
|
|
|
#
|
|
|
|
|
2006-10-19 19:50:23 +08:00
|
|
|
if test -d include
|
|
|
|
for i in include/*.fish
|
|
|
|
. $i
|
|
|
|
end
|
2007-09-09 03:19:40 +08:00
|
|
|
end
|
|
|
|
|