Sublime Forum

Plugin for maintaining a local history of files

#1

Check it out!

http://vishalrana.com/local-history/

0 Likes

#2

Seems a nice plugin. But version control already do this :smiley:
Btw, if you like to (re)write history, an awesome plugin would be a persistent undo, to allow undo even if you close & open a file :wink:

0 Likes

#3

In my understanding version control only maintains history if you check-in the file. With this plugin every time you modify a file, a copy of the old contents is kept in the local history.

PS: Also, not every file is under version control.

0 Likes

#4

It’s a nice plugin, it’s a feature I’ve wanted for a long time.

You should try to do all of your file io in a thread though. On every save it has to do a blocking read, and two blocking writes, which on large files was causing a noticeable lag for me.

0 Likes

#5

@ajpalkovic: Thanks for your input, I will have a look at it.

0 Likes

#6

I have moved saving history to a thread, so its async and doesn’t block. However the compare / replace are still sync intentionally.

0 Likes

#7

Very nice plugin, thanks for it. Just one suggestion. I would prefer to have the “.history” directory outside of Packages as it gets parsed by sublime. *.sublime-commands files from the .history directory show up in the command palette for example. It would be nice to have the path to the history directory as well as the HISTORY_LIMIT configurable in a settings file.

0 Likes

#8

Awesome plugin! Thank you so much! :smile:

0 Likes

#9

Hit the exact same issue :smiley:
“.history” directory must be located outside ST2 packages directory, the best place is probably in the user folder. Don’t know how to do it in an OS independent way but I think that Automatic Backups package actually do it.

Good plugin, thanks for sharing.

0 Likes

#10

[quote=“bizoo”]

Hit the exact same issue :smiley:
“.history” directory must be located outside ST2 packages directory, the best place is probably in the user folder. Don’t know how to do it in an OS independent way but I think that Automatic Backups package actually do it.

Good plugin, thanks for sharing.[/quote]

Fixed! Added another feature to browser through incremental diffs. Let me know if any issues found.

0 Likes

#11

Thanks for the fix :wink:

0 Likes

#12

Amazing!!! The only feature i miss from netbeans :smile: Thanks a lot

0 Likes

#13

Thanks for awesome plugin! Exactly I was looking for.

0 Likes

#14

Just what I was looking for, thanks :smile:

BTW, is there a way to change the “Local History” folder (and therefore all the backuped files) location? I have tried it by adding and modifying the line "history_location": "~" in the LocalHistory.sublime-settings file in some different way as follows:

"history_location": "D:\Applications\.sublime",
"history_location": "D:\\Applications\\.sublime",
"history_location": "D:/Applications/.sublime",

But with no luck until now… I mean, everything continue being saved in the default “C:\Users*USERNAME*.sublime” directory no matter what I put there… I’m on Windows 7 BTW, and I admit this seems like very basic stuff but for some reason I can’t get it to work, so… any clue?

0 Likes

#15

hi Ramon0,
I have the same issue than you, I am on IE7 and no history get saved in C:\Users\USERNAME.sublime.

Did you get this solved by any chance?

thanks!

0 Likes