execute "go get github.com/github/hub"
bash "go get github.com/github/hub"
前者は動くのに後者はなぜか動かず、瞬間で処理が終了してしまっていた。エラーも吐かず正常終了しているように見えるので、原因がわからなかったが、公式ドキュメントを読み原因がわかった。
https://docs.chef.io/resource_execute.html
https://docs.chef.io/resource_bash.html
executeのnameの説明
name is the name of the resource block; when the command attribute is not specified as part of a recipe, name is also the command to be executed
bashのnameの説明
name is the name of the resource block; when the command attribute is not specified as part of a recipe, name is also the name of the command to be executed
ということで、bashの場合は、nameをコマンドとして取り扱ってくれるわけでないということのようです。