I have a bash function i would like to bsub. It is recursively called when i try to source the script, but if i don't source the script it doesn't seem to recognize my function. How do I correctly call besub on a function within the same script file?
my_script(should print "12345"):
#! /bin/sh
function myFunct {
echo $1
}
bsub -q myQueue "source ./my_script; myFunct 12345"