Terminal productivity boost (some Bash aliases)

Hello again,

It’s been a long time since I’ve posted, but it’s been a really busy period..

An icon representing a terminal prompt
Terminal prompt

On to the topic, using a feature such as aliases in a terminal, certainly makes you do things faster.
(To get an intro to aliases and a guide on how to save them permanently, read this)

So I’ve gathered some of mine and uploaded them at Github as a bash-aliases repo.

Here are some:


Append them over to your ~/.bash_aliases file

The above are merely some of the aliases I am using.

In case you have anything to recommend, you could reply here with a comment, or even better fork the project@Github and then create a pull request (more info here).

Also, since we’re taking about terminal productivity tips, a must shortcut to mention is the one of recursive command search.
That is Ctrl + R.
Let’s say you are working on project that is hosted on heroku and you have typed this sequence for the local repo
[code language=”bash” gutter=”false”]
git status
git add <new-file>
rails g model modname
rake db:migrate
git commit
And now you are ready to upload the changes to your heroku repo. What you need to do is push them, which if you have typed it before could be easily found using the recursive search.
So, hit Ctrl+R and write push, then you’ll see the command you want, i.e.  git push origin master

If that’s not the command you want then hit Ctrl + R again, so that you get the 2nd result that matches your search.

Leave a Comment

Your email address will not be published. Required fields are marked *