Is there a way one can execute the bash function in the new XTERM window? Below is what I am trying to do
function test(){
echo "Do some work"
}
Then inside my bash script, I am doing the following:
export -f test
xterm -title "Work1" -e "test" "$date_today" "$time_today" &
# The above I am trying to open xterm, run the function, and pass 2 parameters (date_today and time today)
Currently the above does not work as it complains that test is not defined. Any help would be appreciated