Versionizing

hi,

Yesterday I lost around 5 hours of my work because vvvv completely messed up 4 of my main patches and its xml backups. while this is completely unacceptable, this happened to me for the second time now (not counting the ‘normal’ xml glitches that renders a file unaccessible), so I am looking for a workaround solution that prevents the loss of files in the future. I hope there are a few Windows wizards out that could help me on any of my ideas:

  • using Dropbox

They create a version everytime you save a file and keep it for 30 days on the Pro plan. I think that’s the easiest solution but it costs 99 usd a year and I don’t really need the other Pro features plus I don’t wanna work inside a Dropbox.

  • 3rd party tool

Somebody knows if there is a tool that (like Dropbox) automatically saves every saved version of a file into a (local) database or something? that would be a very nice solution.

  • Windows/Previous Versions

Is there a way to force Windows to create a ‘previous version’. (I don’t know how this feature is called but you can find it in the Properties tab of a file in Windows Explorer). It seems completely arbitrary to me when Windows chooses to automatically create such a version. If vvvv could tell Windows to create a new version when saving a patch that would be very helpful, it would also mean to get rid of those ugly ~.xml files.

  • git

I got every project in git. Is there a way to create a cron job that inserts every file change into git on an predefined interval? Everything is a commit in git right? So it would mean to ‘amend commit’ every file change with a ‘autosave’ message. Or is there another git solution?

Thanks,
any hints appreciated.

ps: Why isn’t vvvv validating the file that belongs to a patch after it saves it (trying to read it)? If validation fails, there should be red flags all over the place (plus: ugly ~.xml files would be unnecessary).

I guess git would be the easiest solution.

If you open git bash, you have a complete bash shell at your disposal, so starting a home-brew autosave.sh script in the git shell, that tries to commit every few minutes/seconds, could do the job for you, I guess.

Here’s something I found for how to use find, to get files changed since a certain time (the previous commit perhaps?).

touch -t `date +%m%d0000` /tmp/$$
find /tmefndr/oravl01 -type f -newer /tmp/$$
rm /tmp/$$

I using mostly Dropbox, and Git for libraries - all is working well.

hi rrrr, i normally just zip folders for that, would be quite nice feature to use zip inside 4v hehe. but can you post maybe some pic how this messed files look like? i don’t remember such troubles on new versions… temps, but that quite predictable. Anyways updating that modulo to backup whole dir not to big deal i think

Backup (File).v4p (10.3 kB)

I have likewise lost many hours when vvvv (27.1) saves corrupt files. The typical pattern is that I will be working on a patch, doing repeated saves, and exit with the patch working just fine. A warning sign that I’m in trouble is that vvvv will crash when exiting, but that doesn’t always happen.

When I try to run the patch later, it doesn’t work, with multiple errors scrolling in the console and/or exceptions, and I have to kill it with task manager. The backup .xml file will be corrupt too since I was doing multiple saves. So then I start an extended session of hacking the .v4p in windiff with a much older known-good version (if I’m lucky enough to have one).

Ideally there should be some source code control available within vvvv that would save a revisioned set of a patch and all sub-patches, just like a real development environment.

Since I recall there is a way to walk the patch list in vvvv, this should be doable. Wasn’t there some patch that put all the sub-patches into a folder? It could be taken one step further and zip’d into a date-time file. I’ll try to take a look for it.

But of course, it would be very nice if vvvv didn’t save corrupt files in the first place… (:^P) As a result I’ve gotten in the habit of almost always doing a “save-as” with a manually-versioned name, and exiting and reloading frequently to make sure I’m not putting my work into a rat-hole.

Good luck!

as long as timeliner has no UNDO I use autosafe module by catweasel.
didn’t work with b26, but works for me with >b27
the main problem is saving correct paths: v4 get confused and mixed up or replace local (specific and modified module, fx, dll) files from subdirectory with stuff from lib

autosave.v4p (18.0 kB)

@antokhio that’s how the patch looks like in Notepad++

Every other text editor won’t display anyting-although the file size is 70KB.

Thanks for those backup patches. As far as I unterstand, they have to go into every single sub patch right? anybody got a solution where there lives a single backup patch in the root that auto-saves all them sub patches too?

Other idea: couple of weeks (months?) ago someone suggested using clipboard managers to reuse code snippets. A nice solution could be to automatically send every (sub) patch into the clipboard on a timed interval, and the clipboard manager organizes the rest. can someone recommend a good clipboard manager for Windows?

that’s rather strange, i think i’ve seen something like this screenshot
but still try to find where could that come from? Evaluate, buggy plug, huuuge spread are potential treat.
memory leak might result that i think

i know you are all git lovers ;) anyway,we use http://www.visualsvn.com/server/ pretty successful in our studio. combined with http://tortoisesvn.tigris.org/ on the client pc’s. migrating the server to a laptop for “outdoor” patching is easy as a pie.

well, everything concering this solution does not need any commandline nonsense or indepth knowledge of branches or pulls,pushs. just commit often and you’re save. if something goes wrong v4-wise, just revert to last revision.