DEV Community

Cover image for The fuck
Tomas Sirio
Tomas Sirio

Posted on

1

The fuck

I use the terminal every day and I've found myself mistyping the command that I wanted to input fairly often.

Here is where The Fuck comes in:

The Fuck is a magnificent app, inspired by a @liamosaur tweet, that corrects errors in previous console commands.

fuck

As you can see, The Fuck is a CLI application that takes your last failed command and fixes it for you. It also suggests you the --upstream push option on your fresh new git branch so that you don't have to copy and paste it (I use this every single time that I create a new branch)

Installation

You are going to need:

  • python (3.4+)
  • pip
  • python-dev

On Os X:

brew install thefuck

On Debian Based Systems:

sudo apt update
sudo apt install python3-dev python3-pip python3-setuptools
sudo pip3 install thefuck

On other systems:

pip install thefuck

Usage

The application is really simple to use. Once installed, try typing a command that you want to use. For example, let's try a git checkout to a certain branch on an existing repository:

Alt Text

You can also use the --yeah parameter to skip the command confirmation:

Alt Text

My favorite use is for the upstream push as I mentioned before:

Alt Text

Lastly, if there are no fucks to give, the application will let you know exactly that:

Alt Text

Repository

Check the repository out and give a fuck for yourselves.

Happy new year
Happy fuck coding

Heroku

Build apps, not infrastructure.

Dealing with servers, hardware, and infrastructure can take up your valuable time. Discover the benefits of Heroku, the PaaS of choice for developers since 2007.

Visit Site

Top comments (0)

Sentry image

See why 4M developers consider Sentry, “not bad.”

Fixing code doesn’t have to be the worst part of your day. Learn how Sentry can help.

Learn more