Just starting with groovy, be grateful if someone could help me out.
I'm writing a function in a script that will accept a parameter.
def print_arg(def arg){
println "$arg"
}
I save that file as test.groovy.
How do I test throwing arguments at the function from the command line?
groovy test.groovy print_arg input
groovy test.groovy print_arg 'input'
groovy test.groovy print_arg(input)
None of the above work
I suspect I'm doing something fundamentally daft :-)
Any tips, greatly appreciated.