Reviving and Revamping my btrfs backup program Snap-In-Time

If you’ve been following my blog for a long time, you know that back in 2014 I was working on a Python program to create hourly btrfs snapshots and cull them according to a certain algorithm. (See all the related posts here: 1, 2, 3, 4, 5, 6, 7, 8, 9) The furthest I ever got was weekly culling. Frankly, life and school contributed a good excuse not to keep going because I had created a huge headache for myself by attempting to figure out the date and cover all the possible corner cases with unit tests. This is what my code looked like in 2014.

As you know, I’ve recently been on a Python programming binge due to reading a few books that taught me advanced topics and how to properly structure Python code folders. One of the books also had a reminder to check the Python modules (built-in and others) before implementing something that has already been done and well-tested. I’ve also gotten way better at reading and understanding the official Python documentation. So I discovered the datetime module that alleviates almost all the pain I was having when working on Snap-In-Time and spent a week or two on a code sprint. I’m now almost back to the same functionality I had before, but with MUCH cleaner and more maintainable code! Also, it’s become my third package on PyPi.

Snap-in-Time on PyPi

Now I’m jazzed to keep working on it and making it better and better.

Published by Eric Mesa

To find out a little more about me, see About Me