Félix Albertos Marco

Utilities

Home/resources/util>

Utilities

[resources] [util]

Bash

Use an edition interface in line vim style in your bash shell, just include the following opcion in your ~/.bashrc file:

set -o vi

Bonus: If you want to show the current mode, which is really convenient, try including the following code in your /etc/inputrc file:

set show-mode-in-prompt on
set vi-cmd-mode-string "|c|"
set vi-ins-mode-string "|i|"

The result will look something like this:

|i|user@machine:~$ Hello wo

Rename a number of files in nested folders:

find */*.ext -type f -exec rename 's/oldtext/newtext/' '{}' \;

Suspend from the cli

apt install pm-utils
pm-suspend

Manage music library from the cli

Beets is the best command-line tool for viewing, querying, and renaming your music collection.

$ pip install beets
$ beet config -e
$ beet import path
$ beet list
$ beet update

PDF

Merge pdf pages

$ pdfunite
pdfunite version 22.02.0
Copyright 2005-2022 The Poppler Developers - http://poppler.freedesktop.org
Copyright 1996-2011 Glyph & Cog, LLC
Usage: pdfunite [options] <PDF-sourcefile-1>..<PDF-sourcefile-n> <PDF-destfile>
  -v             : print copyright and version info
  -h             : print usage information
  -help          : print usage information
  --help         : print usage information
  -?             : print usage information

Vim

Vim is a highly configurable text editor built to make creating and changing any kind of text very efficient. The way that you interact with it make it more than just a text editor (or not), a way of interacting with your entire computer.

You can find a comprehensive list of applications using Vim keybindings in the The Keybindings Everywhere - The Ultimate List.

Window Management

Take a screenshot

$ import screenshot.png

Part of the imagemagick package.

Configure conected devices

autorandr - automatically select a display configuration based on connected devices.

This software can be used to save/restore monitors connected on I3.

Cast Audio&Video from Linux to Google Cast devices

Cast your Linux or macOS audio and video to your Google Cast devices, e.g. Chromecast.

$ mkchromecast --video --screencast