Extract archive in ruby on windows
I am having trouble extracting a zip-archive on a windows machine. I am currently working on an extension for buildr, which works fine on Linux and Mac OS X. I am using a built-in function in buildr to extract my archive which is built on top开发者_StackOverflow of rubyzip but rubyzip fails on windows with:
NotImplementedError : symlink() function is unimplemented on this machine
Anyone knows how I can make this work on Windows.
Install unzip, put it in your system path, and then simply
myfile = "foo.zip"
`unzip #{myfile}`
The `...`
command in Ruby allows you to execute system commands.
精彩评论