james@bigtex.cactus.org (James Van Artsdalen) (06/14/89)
> Date: Sat, 10 Jun 89 21:38:00 -0700 > From: Mac Pigman <gwp@dido.caltech.edu> > (One thing I miss is csh's .logout.) Try this in .bash_profile to get what you want. trap '. $HOME/.logout' 0 Remember that the command string gets evaluated twice: one when the trap is set, and once when run. --- James R. Van Artsdalen james@bigtex.cactus.org "Live Free or Die" Dell Computer Co 9505 Arboretum Blvd Austin TX 78759 512-338-8789
bfox@AUREL.CALTECH.EDU (Brian Fox) (06/14/89)
Posted-Date: Tue, 13 Jun 89 22:59:17 CDT Date: Tue, 13 Jun 89 22:59:17 CDT From: james@bigtex.cactus.org (James Van Artsdalen) > Date: Sat, 10 Jun 89 21:38:00 -0700 > From: Mac Pigman <gwp@dido.caltech.edu> > (One thing I miss is csh's .logout.) Use ~/.bash_logout. Brian Fox
composer@BU-CS.BU.EDU (Jeff Kellem) (06/14/89)
| Posted-Date: Tue, 13 Jun 89 22:59:17 CDT | Date: Tue, 13 Jun 89 22:59:17 CDT | From: james@bigtex.cactus.org (James Van Artsdalen) | | > Date: Sat, 10 Jun 89 21:38:00 -0700 | > From: Mac Pigman <gwp@dido.caltech.edu> | | > (One thing I miss is csh's .logout.) | | Try this in .bash_profile to get what you want. | | trap '. $HOME/.logout' 0 But, ~/.bash_logout (if it exists) already gets executed when you logout of a bash login shell. So, there's really no need for the trap. The method above works, except that ~/.logout will get executed even when you exit out of a bash shell that is not a login shell. (I don't believe it should unless bash is a login shell.) Also, the ~/.logout file could probably consist of csh commands, since .logout is a csh thing, so renaming it to something like ~/.bash_logout would help if you did want to do it with 'trap'. | James R. Van Artsdalen james@bigtex.cactus.org "Live Free or Die" | Dell Computer Co 9505 Arboretum Blvd Austin TX 78759 512-338-8789 -jeff Jeff Kellem INTERNET: composer@bu-cs.bu.edu (or composer%bu-cs.bu.edu@bu-it.bu.edu) UUCP: ...!harvard!bu-cs!composer