Package: xxcmd
xxcmdxxis a Linux shell command.xxremembers other shell commands, so you don't have to.InstallationpipRequires Python 3. Installation is simple usingpip.pipinstallxxcmdOrpip3on Ubuntu or Debian based distros.If typingxxat a command prompt gives you "Command not found", you likely don't have~/.local/binon your PATH. Either install globally withsudo pip install xxcmdor add~/.local/binto your PATH.Arch LinuxThexxcmdpackage in availabe in the AUR.Basic Usage ExamplesUsingxxyou build up a database of useful commands and search and execute them whenever you like.Adding Command ExamplesMost basic example, adding thetopcommand.xx-atopAdd theducommand to display size of all files and directories in the current directory.xx-adu--max-depth=1-h.Add the same command but with a friendly (searchable) label:xx-a[FileSizes]du--max-depth=1-h.Adding our favourite ssh command:xx-a[SSHBestHost]ssh-i~/.ssh/mykey.pemme@myhost.comAdd the last command you executed:xx-a!!Add the last command you executed with a descriptive label:xx-a[MyCoolLabel]!!If adding commands containing characters that are interpreted by your shell, such as|or&&enclose the command in quotes. You can also use double quotes with bash's last command operator:xx-a[CommandwithPipes]"!!"End the label name with an exclamation mark and you will be asked for confirmation before this command is executed.xx-a[DangerousCommand!]echo"boo"Browse and Search Commands InteractivelyRunxxwith no options to enter the interactive view.xxQuick Search and Executexxcan search for matching commands and if only one match is found it will be immediately executed.The search looks in labels and commands.So one way to execute theducommand we added above is:xxsizesWhich finds a match on our label "File Sizes" and runs the associated command.We could immediately ssh connect with:xxbestWhich would match our label "SSH Best Host".Interactive ViewInvokingxxwithout options will open the interactive view. This presents a list of all commands with an interactive search.Keys:Up/Down- navigate the list of commands.Delete- remove the currently selected commandReturn- execute the currently selected commandEscape- exitF1orCTRL+E- Edit the label of the currently selected itemF2orCTRL+I- Edit the label of the currently selected itemF3orCTRL+G- Add a new command.Any other key press is added to the interactive search to filter the command list.Further Usageusage: xx [-h] [-a ...] [-b] [-e] [-i URL] [-c] [-f FILE] [-g] [-l] [-m] [-n]
          [-p PADDING] [-s] [-t] [-v]
          [SEARCH ...]

Remembers other shell commands, so you don't have to.

positional arguments:
  SEARCH                Search for a matching command and run it immediately.

optional arguments:
  -h, --help            show this help message and exit
  -a ..., --add ...     Add the given command to the database. Command may
                        begin with a label enclosed in square brackets [label]
                        <cmd>
  -b, --no-border       Don't display a window border.
  -e, --no-help         Don't display the shortcut key help footer.
  -i URL, --import-url URL
                        Import a command database from the given URL. Merge
                        into existing database.
  -c, --create-config   Create a config file in the users home directory if
                        one doesn't already exist.
  -f FILE, --db-file FILE
                        Use the command database file specified rather than
                        the default.
  -g, --no-global-database
                        Don't load the global system database.
  -l, --list            Print all commands in the database
  -m, --no-commands     Don't show commands in interactive view.
  -n, --no-echo         Don't echo the command to the terminal prior to
                        execution.
  -p PADDING, --label-padding PADDING
                        Add extra padding between labels and commands.
  -s, --search-all      Search both labels and commands. Default is to search
                        only labels first, and only search in commands if
                        searching for labels resulted in no search results.
  -t, --no-labels       Don't display command labels.
  -v, --version         Display program version.ConfigurationIn addition to the command line switches a configuration file can be used. The file named.xxcmdrcin the current users home directory is loaded if present.Some options are only configurable through the config file.An example file demonstrating all possible options (and the system defaults):[xxcmd]
echo-commands = yes
show-labels = yes
show-commands = yes
align-commands = yes
draw-window-border = yes
label-padding = 2
bracket-labels = no
bold-labels = yes
whole-line-selection = yes
search-labels-only = no
search-labels-first = yes
shell = default
sort-by-label = yes
sort-by-command = no
sort-case-sensitive = yes
display-help-footer = yes
load-global-database = yesCommand line switches take precedence over configuration file options.shellcan be set to the full path of the shell to be used to execute commands, such as/bin/sh. If set todefaultthe environmental variableSHELLis inspected to use the default OS shell.