You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I recently ran this script in a sublime instance on my (Windows) development PC. Unfortunately I was under the impression that it would process open files, not every folder open in my project. I happened to have a large number of folders open at the time. As you would expect, this corrupted a very large number of binary files on my development computer (word documents, excel files, images, power points etc). The script also corrupted all my git repos (See #5).
Many of these were under git control - after blowing away the folders I could clone again and everything was fine. Unfortunately there were a handful of binary files that were only local, and not yet committed to version control. Some of these are very important files that I would very much like to recover.
Can you offer any advice in this regard? My understanding is that this script searches through the binary stream of each file, looking for instances of "\n" and replacing with "\r\n" (on a windows machine), or "\n\r and replacing with "\n" (on a Linux machine). Is this correct?
If my above assumption is correct, am I correct in my understanding that this is a lossy transform? I.e. instances of "\n" would then be co-mingled with instances of "\r\n" in the byte stream, making it non-trivial to reverse the process, recovering the binary file to it's original state?
Can you suggest any means for me to recover these files?
Suggestions from an issue point of view:
Make the README.md warning about backing up files much, much more prominent - maybe move to the top of the file?
Make the install.txt warning about backing up files much, much more prominent - maybe move to the top of the file?
Adjust the script to totally ignore binary files
Remove this package from Sublime Package Control - it's too dangerous for mere mortals.
Thanks for the assistance,
The text was updated successfully, but these errors were encountered:
Update: it seems the process is much more lossy on binary files than I anticipated. Below is a HxD binary diff of a file I had a backup of. On the left is the corrupted file and on the right the backup. As you can see, after the first difference there are vast chunks of missing bytes from the corrupted file :(
Hi @vontio,
This is part issue and part a plea for help :/
I recently ran this script in a sublime instance on my (Windows) development PC. Unfortunately I was under the impression that it would process open files, not every folder open in my project. I happened to have a large number of folders open at the time. As you would expect, this corrupted a very large number of binary files on my development computer (word documents, excel files, images, power points etc). The script also corrupted all my git repos (See #5).
Many of these were under git control - after blowing away the folders I could clone again and everything was fine. Unfortunately there were a handful of binary files that were only local, and not yet committed to version control. Some of these are very important files that I would very much like to recover.
Suggestions from an issue point of view:
README.md
warning about backing up files much, much more prominent - maybe move to the top of the file?install.txt
warning about backing up files much, much more prominent - maybe move to the top of the file?Thanks for the assistance,
The text was updated successfully, but these errors were encountered: