Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options

Re: OT: Does anyone know of a version control system that doesn't use separate files or a repo?

by chrestomanci (Priest)
on Oct 15, 2011 at 21:02 UTC ( #931702=note: print w/replies, xml ) Need Help??

in reply to OT: Does anyone know of a version control system that doesn't use separate files or a repo?

You could write a simple script to copy the file(s) you are working on to a safe place, and append the current data & time to the filename so they are all kept separate. You could even add that script to your cron so it runs every hour or so.

The problem with that approach is that you will end up with thousands of versions of your file, all filling up your disc, and no commit messages to tell you which one contains the edits you are looking for. Far better to create a simple hg or git repository and use that.

One situation where simple copying at frequent intervals might be useful, is if you want to get back from recent editor mistakes where there is no checked in file. On one project I worked on recently, I created a script to put all the files currently out for edit into a time stamped zip file. I had a cron job call that script every ten minutes during working hours.

I used the zip files to get back old versions of the source I was editing, if I realised that the approach to a problem I had spend the last hour on was a dead end, I could easily get back the version from an hour ago.

To be clear this was not a source code version control system, it was just a quick hack to snapshot files that where checked out for edit.

  • Comment on Re: OT: Does anyone know of a version control system that doesn't use separate files or a repo?

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://931702]
[Corion]: choroba: Yes, but the longer I thought about efficient hashes mapping the event type back to their callbacks, and how to keep them in sync, the more I thought that all that optimization might just not be worth it, even if it's horribly inelegant
[Lady_Aleena]: My biggest problem with hashes at the moment is one with 2,501 keys.
[choroba]: how many event types are there?
[Corion]: Also I found that I can't conveniently weaken an array slot, which also is inconvenient, as I want my one-shots to disappear if the caller discards them
[Corion]: choroba: Currently two or three that my program handles (WWW::Mechanize:: Chrome), but there might be more that become interesting
[Corion]: But I don't expect more than 100 to be active at the same time, so I'm not really sure if there is a not-too-fancy data structure that is maintained with few lines of code where the performance is better than the linear scan ;)
[Corion]: But I should do a mock-up program so that others can see what I'm talking about ;)
[robby_dobby]: Corion: I hope you know all too well that passing around "fancy" datastructures is a recipe for disaster :-)
[robby_dobby]: As in, it's-too-fancy- that-it-will-be- messy-to-handle
[choroba]: bit vectors as keys?

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (13)
As of 2017-05-29 07:58 GMT
Find Nodes?
    Voting Booth?