When I first started using the terminal for development it was a strange and awkward thing for me. I couldn’t stop thinking that having a GUI application to run the tasks I was trying to complete was superior and easier. Now, five years later, GUI apps get in my way more than help. GUI apps have become cumbersome to use while the terminal seems natural. If you’ve never used the terminal much in development or you’re just getting into it, here are some tricks I’ve learned that’ll change the way you do things forever.
I upgraded my main server from Ubuntu 12.04 to 14.04 yesterday and after the upgrade Apache didn’t want to serve anything but 500 errors. Turns out that Ubuntu 14.04 brings with it an upgrade to Apache 2.4 (used to be 2.2). One of many issues were errors stemming from
.htaccess files. Here’s how to fix those.
Web hosting is cheap and expensive. Cheap because you can get a small VPS on DigitalOcean for $5 a month and expensive because when you use a VPS you either need to spend time or money to keep essential services like email running. I’m in the process of moving some sites off of MediaTemple and on to Linode and DigitalOcean to save some money. Part of the process requires moving databases around. So, for my own personal future reference and anyone else who may want to bookmark a refresher, here’s how to backup and restore a MySQL database and move it between hosts.
My latest project is broken up into a Ruby core (for the server) and a number of front-end modules for things like themes and dashboard design. I needed a way for developers working on the front-end modules (which are structured as Node/npm compatible packages) to be able to install the built files into the core project. Grunt tasks only work in their root directory and the complexity of the tasks called for something that could be extracted out of the projects and be reuseable. So I’m writing a Node CLI utility. The first problem that needed to be solved was option parsing. This is a story of the state of option parsers in Node, how to write one yourself, and why “
eval() is evil” is misunderstood.
A few months ago I debugged a real hairy issue involving dependencies on different machines running the same cloned git repository. I had begun to write a real lengthy post on how novices debug code vs. how experienced programmers do it. Today I came across this article that explains it much better than I ever could. You should check it out. My thoughts on it are after the jump.
I’ve been using the amazing Sublime Text editor since it came out a few years ago and ended up learning all it’s neat shortcuts almost by accident. Today I want to share all of them. They’ll be here for me to reference and for anyone else who wants a quick and easy reference for Sublime Text shortcuts they don’t know and may want to take advantage of one day. All credit goes to the Sublime Text Unnoficial Documentation for this.
Clients, friends, acquaintances, and hobbyist developers will often ask me “what program” do you use to make websites. No matter how many times I hear the question I’m always taken back. I don’t know how to answer that question. Inevitably, each time I respond in an annoyed/confused tone “What do you mean”? Professionals talking amongst themselves will speak about IDE’s, text editors, terminal emulators, and other specifics, each of which are actually far simpler tools than the one that the less skilled are hoping you’ll tell them is the best. So how is that we go from complex IDE’s like Dreamweaver to simpler tools like text editors as we get better at our craft?
Ever had some strange things happen on the Mac command line? Have you installed or updated Xcode recently? The issue is most likely related to the command line tools. Before you tear your hair out, make sure you check these possible solutions first.