tfenv icon indicating copy to clipboard operation
tfenv copied to clipboard

Calling tfenv from bash script results in syntax error

Open rboarman-sc opened this issue 4 years ago • 1 comments

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.

rboarman-sc avatar Jul 24 '19 23:07 rboarman-sc

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. :-/

osterman avatar Feb 28 '20 04:02 osterman