Move functions from your main script into another file

# main.sh
source ./myFuncs.sh
f1 hello world
# myFuncs.sh
function f1 {
    arg1 = $1
    arg2 = $2
    # Do something with ${arg1}
}