How do I exit a process trough a script?

How do I exit a process trough a script?

Post by Rene Hertel » Tue, 06 Jan 1998 04:00:00



I want to write that writes to the .project the time I logged out. i can't
use the .logout option because I'm not in the original login shell (I'm
usin tC-shell)
I use the following line to add the date to the .project file, but I have
then to exit manually (typing exit at the prompt)

---clip----
#!/bin/posix/sh
echo "Last login `date`" > .project
exit
---clip----

___
You got this message from:

Rene

 
 
 

How do I exit a process trough a script?

Post by Keren Westreic » Tue, 06 Jan 1998 04:00:00


You can make an alias to exit command:

Quote:> alias exit 'date > .project; logout'


 
 
 

How do I exit a process trough a script?

Post by Keren Westreic » Tue, 06 Jan 1998 04:00:00


You can make an alias to exit command:

Quote:> alias exit 'date > .project; logout'

 
 
 

How do I exit a process trough a script?

Post by Rene Hertel » Tue, 06 Jan 1998 04:00:00



C: \> You can make an alias to exit command:

C: \> > alias exit 'date > .project; logout'

That does not work... The shell i use is not a login shell, so I can't use
the logout-command.

I want also add the line "Last login at: 'date'"...

___
You got this message from:

Rene

 
 
 

How do I exit a process trough a script?

Post by Steph » Wed, 07 Jan 1998 04:00:00


: I want to write that writes to the .project the time I logged out. i can't
: use the .logout option because I'm not in the original login shell (I'm
: usin tC-shell)
: I use the following line to add the date to the .project file, but I have
: then to exit manually (typing exit at the prompt)

Even if you're using a custom shell from the one the system logs you in
with, you should still be able to use *that* shell's method of logout
file. What *is* your original login shell? Read the man page on it.

Stephen