Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Windows: \r\n issue #9

Closed
senseysensor opened this issue Nov 18, 2013 · 3 comments
Closed

Windows: \r\n issue #9

senseysensor opened this issue Nov 18, 2013 · 3 comments

Comments

@senseysensor
Copy link

Plugin has serious issue - it does not work correctly on host windows system (windows 8 in my case). As I found, file /tmp/disk_operations_persistent.sh has windows-style EOL ending (\r\n instead of \n), and because of that cannot be executed on startup as is.

I tried to overcome issue by converting this file with dos2unix command on startup and then executing, but anyway it is kludge, you see. Please fix...

@senseysensor
Copy link
Author

Temporary fixed for me locally... changed mode 'r' -> 'rb' in https://github.com/kusnier/vagrant-persistent-storage/blob/master/lib/vagrant-persistent-storage/manage_storage.rb#L74
For sure this file should be already stored locally with LF EOL.

@kusnier
Copy link
Owner

kusnier commented Nov 27, 2013

You mean you changed the mode to wb?

"b" Binary file mode
Suppresses EOL <-> CRLF conversion on Windows. And
sets external encoding to ASCII-8BIT unless explicitly
specified.

Yes. This should fix the Problem. I will fix that.

@kusnier
Copy link
Owner

kusnier commented Nov 27, 2013

Version 0.0.5 release. Please test if this helps.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants