Argh, Git!

08 Sep 2013

Git has left me a broken woman

I spent this day failing to configure a remote Git repository that would deploy this blog to my hosting server. I'm running this site with Jekyll. It was a journey to Jekyll, though.

I had wanted to use the neat blogging engine Toto. There isn't that much code. I am confident that in a few months I will be able to read through it. What really motivated my decision to use it was that I need to learn Git. It seems like the responsible thing: learn a version control system when you're a beginner programmer. Toto is designed, however, for more Ruby friendly hosts, specifically Heroku. Yeah, I have an account on Heroku, and will definitely use it to deploy apps and prototype while at ITP. But what IS a dyno? Heroku is free if you don't use a DYNO. Because I don't know what that is (yes, I went on Stackoverflow), I decided to deploy Toto on my Dreamhost account.

Well. That opened up a whole series of troubles, but they all coalesce into the central problem: I didn't know Git. When using Git to deploy a live website, you need to keep the remote repository empty with a specific script written in a 'hook' file. Then there is another hook file modified specifically for your local directory. I was and still am confused on WHICH file $PATHS these hook files link to. I will link to proper tutorials later. I don't know Git, so even when I eventually found those tutorials it was just 'blahblah, blahblhablha, blah. And blah.'

Before I decided on Jekyll and after failing with Toto, I choose to go with another lightweight blogging system: Wintersmith. It's built on top of Node.js, comes with a Jade plugin (Jade is a popular templating engine for Node apps) and like Toto, and Jekyll and my gurl, Stacey uses Markdown and, I guess, YAML to format and write posts.

Well. Before I was going to install Node.js and the Node Package Manager (npm) on my server, I did a quick site: search for a tutorial and I am so glad I did. It is a VIOLATION of Dreamhost's terms of service to download and attempt to install Node on a shared hosting account. I would have either lost my account or been forced to spend $15/month for a VPS account.

So, what then? Another go at Toto, but I'm not configuring those hooks/post.recieve scripts properly. It's a no-go. There's Mynt, but I really wanted a framework that would enable me to deploy easily via Git or another script. I see the Jekyll link at the bottom of quite a few developers' blogs I read. So, I checked out Jekyll and I like it. I made one last attempt to deploy through Git and again, no-go. I am using an rysnc script (will link later) to push updates and it's great. I'm using Git to track additions, subtractions, and changes to/fro my local directory. I will write another update concerning that system. It should work out fine. Git is an awesome piece of software (and complicated with verbose documentation).

For a novice, Git is easier to use and understand when deploying to a Github-hosted repository. Scott Chacon of GitHub is a great lecturer on the VCS. After this experience, his advice (and enthusiasm) clarified what may have been going wrong, but also why and how a distributed version control system is necessary.

Direct links to posts related to project are below


comments powered by Disqus Categories