Link to home
Start Free TrialLog in
Avatar of Los Angeles1
Los Angeles1

asked on

Linux, using 'exit' in a script

I want to use exit in a script in RHEL 6.x

Something like:

pwd
user1
exit
su - user1

Open in new window


This will restart my .profile

I know there are other ways of doing this, but I want to concentrate on how to use exit in a script

How can I do this ?

Thanks in advance
SOLUTION
Avatar of worm-getter
worm-getter

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
ASKER CERTIFIED SOLUTION
Avatar of farzanj
farzanj
Flag of Canada image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial