tfenv
tfenv copied to clipboard
Calling tfenv from bash script results in syntax error
Using this code, look at line 30:
https://github.com/cloudposse/terraform-root-modules/blob/master/aws/tfstate-backend/scripts/init.sh
Running the terraform project results in this error:
scripts/init.sh: eval: line 42: syntax error near unexpected token `('
make: *** [init] Error 2
Running tfenv straight from the command line works fine.
Given that the project does not compile under windows, I am unsure how to debug this further.
scripts/init.sh: eval: line 42: syntax error near unexpected token
('`
My best guess is this is due to using sh
and not bash
; possibly sh
is the default in whatever shell you are in? Apologies - we have never tried using it on anything other than Linux/MacOS. :-/