]> git.pld-linux.org Git - packages/fortune-mod.git/commitdiff
- don't exit() from /etc/profile
authorradek <radek@pld-linux.org>
Tue, 23 May 2006 13:23:50 +0000 (13:23 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    fortune-mod.csh -> 1.5
    fortune-mod.sh -> 1.5

fortune-mod.csh
fortune-mod.sh

index 30e50ced291177dd94fb93551f7e323887a0cf37..64c84d29a003e8b6e11771b87895efbe5f6552e1 100644 (file)
@@ -1,7 +1,8 @@
 #!/bin/csh
 # skip fortunes on cron mails.
-tty -s || exit 0
-
-echo
-fortune -s
-echo
+tty -s
+if ( $? == 0 ) then
+       echo
+       fortune -s
+       echo
+endif
index ef2aa6893fd83849ae5771af5ec14ab2139c2bc5..2aaafada4f9b9c5d6bf700479b3dd894abc3a8eb 100644 (file)
@@ -1,6 +1,7 @@
 #!/bin/sh
 # skip fortunes on cron mails.
-if (tty -s); then
+tty -s
+if [ $? -eq 0 ]; then
        echo
        fortune -s
        echo
This page took 0.167626 seconds and 4 git commands to generate.