diff options
author | Bill Nottingham <notting@redhat.com> | 2008-04-29 11:48:38 -0400 |
---|---|---|
committer | Bill Nottingham <notting@redhat.com> | 2008-04-29 11:48:38 -0400 |
commit | 39d1593aad51817f5b64a9e95f2144dfaa018ebb (patch) | |
tree | 76b654e6882cffa74ccab957c69a15ca53f5e98b /lang.csh | |
parent | 98a6595a35e51c34bee9c66ab8d9fc4302d3301c (diff) | |
download | initscripts-39d1593aad51817f5b64a9e95f2144dfaa018ebb.tar initscripts-39d1593aad51817f5b64a9e95f2144dfaa018ebb.tar.gz initscripts-39d1593aad51817f5b64a9e95f2144dfaa018ebb.tar.bz2 initscripts-39d1593aad51817f5b64a9e95f2144dfaa018ebb.tar.xz initscripts-39d1593aad51817f5b64a9e95f2144dfaa018ebb.zip |
Canonicalize the behavior. (#372151)initscripts-8.74-1
If no LANG is set, read system and then user configuration.
If an existing one is set (via GDM, ssh, etc.) only read the
user-specific customizations.
Diffstat (limited to 'lang.csh')
-rwxr-xr-x | lang.csh | 17 |
1 files changed, 9 insertions, 8 deletions
@@ -1,21 +1,22 @@ # /etc/profile.d/lang.csh - set i18n stuff set sourced=0 + if ($?LANG) then - set sourced=1 set saved_lang=$LANG -endif - -foreach file (/etc/sysconfig/i18n $HOME/.i18n) - if ( -f $file ) then + if ( -f $HOME/.i18n ) then eval `grep -v '^[:blank:]*#' $file | sed 's|\([^=]*\)=\([^=]*\)|setenv \1 \2|g' | sed 's|$|;|'` set sourced=1 endif -end - -if ($?saved_lang) then setenv LANG $saved_lang unset saved_lang +else + foreach file (/etc/sysconfig/i18n $HOME/.i18n) + if ( -f $file ) then + eval `grep -v '^[:blank:]*#' $file | sed 's|\([^=]*\)=\([^=]*\)|setenv \1 \2|g' | sed 's|$|;|'` + set sourced=1 + endif + end endif if ($sourced == 1) then |