Search code examples
batch-filechef-infraberkshelf

Commands after berks not running in batch file


I have a batch file that runs a few processes to test and build my chef cookbooks

del test.tar.gz
berks vendor --delete
berks package test.tar.gz <- doesnt execute

--or--

del test.tar.gz
berks package test.tar.gz 
berks vendor --delete  <- doesnt execute

the problem is that no commands after the first berks command ever get executed.

I've tried adding several different commands after berks vendor however nothing will run, even though the previous command completes successfully.

I cant find anything in the documentation about this, how can I get all my commands to run?


Solution

  • The binstub we create on Windows is berks.bat. So you need to use call berks.bat instead. This is a weird limitation of Windows batch scripts.