I do have several shell scripts whom are get activate not really behind each other.
But I want to stay in the same terminal window.
To simplify the problem, lets say that as example
first script. - cd to the working directory second. - do some things and get files from that directory third. - dome more thing on the newly files/folders in that directory. fourth. - ....
How can I let script 2 and 3 ( all the script thus ) run in that very same directory and window that is opened during script 1?
F.e how can I avoid using the full path to that folder for every file.
EDIT: After adayzdone's answer I realize that I forgot to mention that I need also administrator privileges for one of the scripts
EDIT2: For now I use this
tell application "Terminal"
set newTab to do script
set current settings of newTab to settings set "Grass"
do script "bin/sh/ echo 'xx' | su;" in newTab
do script "cd " & quoted form of realParentPath in newTab
do script shellscript1 in newTab
do script shellscript..n in newTab
activate
end tell
but still no dice with the privileges.