aboutsummaryrefslogtreecommitdiffstats
path: root/lang.csh
diff options
context:
space:
mode:
authorVille Skyttä <ville.skytta@iki.fi>2010-02-21 21:21:48 +0200
committerBill Nottingham <notting@redhat.com>2011-02-28 15:31:44 -0500
commit5212d0a596d67bbd2f5effdd3686c123f778078f (patch)
tree78f41b7fd9ed97f6326a61c7da25f0b9fabec0df /lang.csh
parent681717364c786083356ebe5d92c4cc6fd73af307 (diff)
downloadinitscripts-5212d0a596d67bbd2f5effdd3686c123f778078f.tar
initscripts-5212d0a596d67bbd2f5effdd3686c123f778078f.tar.gz
initscripts-5212d0a596d67bbd2f5effdd3686c123f778078f.tar.bz2
initscripts-5212d0a596d67bbd2f5effdd3686c123f778078f.tar.xz
initscripts-5212d0a596d67bbd2f5effdd3686c123f778078f.zip
Drop some unnecessary command invocations.
Diffstat (limited to 'lang.csh')
-rwxr-xr-xlang.csh4
1 files changed, 2 insertions, 2 deletions
diff --git a/lang.csh b/lang.csh
index caa058bc..e8560b24 100755
--- a/lang.csh
+++ b/lang.csh
@@ -5,7 +5,7 @@ set sourced=0
if ($?LANG) then
set saved_lang=$LANG
if ( -f "$HOME/.i18n" ) then
- eval `grep -v '^[[:blank:]]*#' "$HOME/.i18n" | sed 's|\([^=]*\)=\([^=]*\)|setenv \1 \2|g' | sed 's|$|;|'`
+ eval `sed -ne 's|^[[:blank:]]*\([^#=]\{1,\}\)=\([^=]*\)|setenv \1 \2;|p' "$HOME/.i18n"`
set sourced=1
endif
setenv LANG $saved_lang
@@ -13,7 +13,7 @@ if ($?LANG) then
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|$|;|'`
+ eval `sed -ne 's|^[[:blank:]]*\([^#=]\{1,\}\)=\([^=]*\)|setenv \1 \2;|p' $file`
set sourced=1
endif
end