How git, github, and LaTeX Can Save Your Ass
Around the month of March, I discovered LaTeX, the popular typesetting engine, and decided that in order to learn how to use it, I'd use it for all homework assignments until the end of the year. So I did, and to this day, all of my homework assignments since March 27th have been authored with LaTeX.
A little later than that, I stumbled upon git, the distributed version control system that's all the rage nowadays. Because it's decentralized, you can have a local repository that you can commit to and mess with on your home machine, and then push updates back up to the Internet if you have a main git repository somewhere.
So then it clicked. I'd use git and LaTeX together. git to manage revisions I've made to projects, so if I screwed something up, no big deal, I could restore from the previous revision. LaTeX would be used because git originally dealt with source code, and LaTeX documents are essentially macros. That would mean running diffs on revisions would be readable, unlike binary file formats like RTF or Word's .doc files.
A month ago, I signed up for github. This is what really makes it click for me.
github is a git repository host. They have a free plan (100MB max storage, more on that limitation later) and essentially everyone can have their projects hosted on a git repository. Not only is their website amazing, but pushing an update to github is as simple as typing 'git push origin master'.
And this simplicity is what will save your ass.
If you're a mildly braindead person like me who accidentally forgets to print a history project that's due after lunch, but you typed in that one command after committing, that .tex file (and in my case, .pdf file as well) is automatically available from anywhere in the world you can log into.
So you just have to find a working computer, log in, download the latest revision, print it, and you're safe.
Four words saved my ass. No needing to type in a complicated ftp URL or launch a new app or anything. Four words and a password equals an automatic backup and being able to access it from anywhere.
Miracle of the year.
Comments