This week's book giveaway is in the General Computing forum. We're giving away four copies of Arduino in Action and have Martin Evans, Joshua Noble, and Jordan Hochenbaum on-line! See this thread for details.
Is there a way to clear out old versions of a file in git? I have some files where I don't need a full revision history, just the last couple versions.
Most version control systems don't keep complete copies of every generation of a file, only the differences between the generations. Obviously, this works better when you're storing generations of source code than generations of binary files, though some systems have the ability to detect differences even in certain types of binary files.
Version control systems are based on the idea that everything is important or it wouldn't be in the Version control system, so chewing holes in the archive is counter-productive. If you really don't care about recreating how the system was back last September, you'd be better off constructing a new archive (or project archive), copying the current system over and simply deleting the whole previous archive.
For internal IT usage, only keeping recent generations might seem reasonable, but VCS systems were intended to support mass-market (including open-source) software, and if people could, they'd still be calling Microsoft for support for Windows 95, which is why it's preferable for them to be able to construct the software as it existed back then (and still does on the client's computer).
Customer surveys are for companies who didn't pay proper attention to begin with.
Bai Shen
Ranch Hand
Joined: Sep 24, 2008
Posts: 323
posted
0
Tim Holloway wrote:Most version control systems don't keep complete copies of every generation of a file, only the differences between the generations. Obviously, this works better when you're storing generations of source code than generations of binary files, though some systems have the ability to detect differences even in certain types of binary files.
Version control systems are based on the idea that everything is important or it wouldn't be in the Version control system, so chewing holes in the archive is counter-productive. If you really don't care about recreating how the system was back last September, you'd be better off constructing a new archive (or project archive), copying the current system over and simply deleting the whole previous archive.
For internal IT usage, only keeping recent generations might seem reasonable, but VCS systems were intended to support mass-market (including open-source) software, and if people could, they'd still be calling Microsoft for support for Windows 95, which is why it's preferable for them to be able to construct the software as it existed back then (and still does on the client's computer).
-nods- I understand that it's not a normal request. And that it's a bad setup. However, it's something I've inherited, and until I have a chance to redo everything, I'm stuck with it. Just trying not to fill up the disk with multiple versions of a binary file.