Briefly describe the bug you are facing.
➜ ~ sam --version
SAM CLI, version 0.13.0
➜ ~ sam init --runtime golang
Usage: sam init [OPTIONS]
Error: Invalid value for "-r" / "--runtime": invalid choice: golang. (choose from dotnetcore1.0, go1.x, dotnet, java, nodejs6.10, nodejs8.10, dotnetcore2.1, nodejs, ruby, python3.7, dotnetcore2.0, dotnetcore, go, python3.6, python2.7, java8, python, ruby2.5)
➜ ~ sam init --runtime go
[+] Initializing project structure...
Error: An error occurred while generating this sam-app: A valid repository for "/usr/local/Cellar/aws-sam-cli/0.13.0/libexec/lib/python3.7/site-packages/samcli/local/init/templates/cookiecutter-aws-sam-hello-go" could not be found in the following locations:
/usr/local/Cellar/aws-sam-cli/0.13.0/libexec/lib/python3.7/site-packages/samcli/local/init/templates/cookiecutter-aws-sam-hello-go
/usr/local/Cellar/aws-sam-cli/0.13.0/libexec/lib/python3.7/site-packages/samcli/local/init/templates/cookiecutter-aws-sam-hello-go
A template is created
sam --version: 0.13.0Add --debug flag to command you are running
Just ran across this issue.
They changed the name of the directory from
/usr/local/Cellar/aws-sam-cli/0.13.0/libexec/lib/python3.7/site-packages/samcli/local/init/templates/cookiecutter-aws-sam-hello-go
to
/usr/local/Cellar/aws-sam-cli/0.13.0/libexec/lib/python3.7/site-packages/samcli/local/init/templates/cookiecutter-aws-sam-hello-golang
In order to get this working just rename the directory back to
/usr/local/Cellar/aws-sam-cli/0.13.0/libexec/lib/python3.7/site-packages/samcli/local/init/templates/cookiecutter-aws-sam-hello-go
I would create a back of the original just in case. But this seems to be a simple fix.
Was release in v0.14.1
Closing
Most helpful comment
Just ran across this issue.
They changed the name of the directory from
/usr/local/Cellar/aws-sam-cli/0.13.0/libexec/lib/python3.7/site-packages/samcli/local/init/templates/cookiecutter-aws-sam-hello-goto
/usr/local/Cellar/aws-sam-cli/0.13.0/libexec/lib/python3.7/site-packages/samcli/local/init/templates/cookiecutter-aws-sam-hello-golangIn order to get this working just rename the directory back to
/usr/local/Cellar/aws-sam-cli/0.13.0/libexec/lib/python3.7/site-packages/samcli/local/init/templates/cookiecutter-aws-sam-hello-goI would create a back of the original just in case. But this seems to be a simple fix.