The Linux Swiss army knife

Commands that will make you forget the GUI

Kesk -*-
CodeX

--

Photo by Miguel Á. Padriñán: https://www.pexels.com/photo/flat-lay-shot-of-tools-3930091/

Not long ago, I wrote a post with 25 one-command-liners that allow you to do complex things with just one line without using the graphical interface. Now, I will show you a list of commands to turn you into the perfect Linux mechanic.

Note: All commands have been tested on ubuntu 20.04. To execute some commands, you will need administrator permissions.

System information

Check the battery’s status via the terminal

This command outputs a lot of status and statistical information about the battery.

$ upower -i /org/freedesktop/UPower/devices/battery_BAT0

In my case, I’m using ubuntu on a virtualized machine, so it doesn’t show relevant stats, but if you try it on a native installation, it will show you a lot of helpful information.

Screen with the result displayed on the command line.

Time the machine has been running

The <uptime> command returns information about how long the system has been running since it was started up the last time.

--

--

Kesk -*-
CodeX
Writer for

Software engineer - software Enthusiast - Sci-Fi writer.