Created
April 16, 2013 23:08
-
-
Save dougireton/5400426 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# include Windows::Helper from Opscode Windows Cookbook | |
::Chef::Recipe.send(:include, Windows::Helper) | |
# now you can call helper methods like win_friendly_path directly | |
my_batch_file = win_friendly_path( | |
::File.join( node['cookbook']['batch_dir'],'foo.bat')) | |
execute "My batch file" do | |
command my_batch_file | |
creates "e:/logs/my_batch_file.log" | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I find that this doesn't work. My path still has single slashes
\
https://gist.github.com/spuder/f1eeecc65b2b8245258e#comment-1483481