[26511] in Source-Commits
/svn/athena r25601 - trunk/debathena/debathena/dotfiles
daemon@ATHENA.MIT.EDU (Jonathan D Reed)
Mon Jul 2 09:48:22 2012
Date: Mon, 2 Jul 2012 09:48:20 -0400
From: Jonathan D Reed <jdreed@MIT.EDU>
Message-Id: <201207021348.q62DmKiI019541@drugstore.mit.edu>
To: source-commits@MIT.EDU
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Author: jdreed
Date: 2012-07-02 09:48:20 -0400 (Mon, 02 Jul 2012)
New Revision: 25601
Modified:
trunk/debathena/debathena/dotfiles/bashrc
trunk/debathena/debathena/dotfiles/cshrc
Log:
- Remove error message skew between shells
- Use -eq, not = in bash tests
Modified: trunk/debathena/debathena/dotfiles/bashrc
===================================================================
--- trunk/debathena/debathena/dotfiles/bashrc 2012-07-01 16:28:18 UTC (rev 25600)
+++ trunk/debathena/debathena/dotfiles/bashrc 2012-07-02 13:48:20 UTC (rev 25601)
@@ -149,19 +149,19 @@
if [ "${skip_sanity_checks+set}" != set ]; then
missing=0
echo $path | /usr/bin/tr ':' '\n' | /bin/grep -Fqx /bin
- [ $? = 0 ] || missing=1
+ [ $? -eq 0 ] || missing=1
echo $path | /usr/bin/tr ':' '\n' | /bin/grep -Fqx /usr/bin
- [ $? = 0 ] || missing=1
+ [ $? -eq 0 ] || missing=1
if [ $missing -eq 1 ]; then
- text="You appear to have incorrectly modified your PATH variable in your dotfiles,\nand as such have deleted /bin and/or /usr/bin from your PATH, which\nwill likely cause this login session to fail. Please correct this problem.\nYou can set the skip_sanity_checks variable to disable this message."
+ text="You appear to have incorrectly modified your PATH variable in your dotfiles,\nand as such have deleted /bin and/or /usr/bin from your PATH, which\nwill likely cause this login session to fail. Please correct this problem.\nThis warning can be disabled with 'skip_sanity_checks=t' in ~/.bashrc.mine."
echo -e "$text" >&2
[ -n "$DISPLAY" ] && /usr/bin/zenity --warning --text="$text"
fi
if [ -n "$LD_ASSUME_KERNEL" ]; then
unset LD_ASSUME_KERNEL
- text="In your shell customizations, you set LD_ASSUME_KERNEL. This is a bad idea.\nIt has been unset.\nIf you really did want that, set the skip_sanity_checks variable in your .bashrc.mine."
+ text="In your dotfiles, you set LD_ASSUME_KERNEL. This generally causes undesirable behavior.\nIt has been unset for you.\nIf you really wanted it set, you can add 'skip_sanity_checks=t' to your ~/.bashrc.mine."
echo -e "$text" >&2
- [ -n "$DISPLAY" ] && /usr/bin/zenity --warning --text="$text"
+ [ n "$DISPLAY" ] && /usr/bin/zenity --warning --text="$text"
fi
fi
Modified: trunk/debathena/debathena/dotfiles/cshrc
===================================================================
--- trunk/debathena/debathena/dotfiles/cshrc 2012-07-01 16:28:18 UTC (rev 25600)
+++ trunk/debathena/debathena/dotfiles/cshrc 2012-07-02 13:48:20 UTC (rev 25601)
@@ -194,7 +194,7 @@
set missing=1
endif
if ( $missing == 1 ) then
- set text="You appear to have incorrectly modified your PATH variable in your dotiles,\nand as such have deleted /bin and/or /usr/bin from your PATH, which\nwill likely cause this login session to fail. Please correct this problem.\nThis warning can be disabled by setting the skip_sanity_checks variable."
+ set text="You appear to have incorrectly modified your PATH variable in your dotiles,\nand as such have deleted /bin and/or /usr/bin from your PATH, which\nwill likely cause this login session to fail. Please correct this problem.\nThis warning can be disabled with 'set skip_sanity_checks=t' in ~/.cshrc.mine."
echo "$text" > /dev/stderr
if ( $?DISPLAY) then
/usr/bin/zenity --warning --text="$text"
@@ -202,7 +202,7 @@
endif
if ( $?LD_ASSUME_KERNEL ) then
unsetenv LD_ASSUME_KERNEL
- set text="Setting LD_ASSUME_KERNEL in your dotfiles is a bad idea.\nIt has been unset for you.\nSet the skip_sanity_checks variable if you really wanted it."
+ set text="In your dotfiles, you set LD_ASSUME_KERNEL. This generally causes undesirable behavior.\nIt has been unset for you.\nIf you really wanted it set, you can add 'set skip_sanity_checks=t' to your ~/.cshrc.mine."
echo "$text" > /dev/stderr
if ( $?DISPLAY) then
/usr/bin/zenity --warning --text="$text"