Skip to content

quackduck/tii

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

42 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Tii

On most GNU/Linux systems, when a command isn't found, a message showing what to run to install the command is shown. However, macOS doesn't have this.

This tool adds a similar function with support for macOS using the Homebrew package manager. Instead of simply printing the best matches, Tii shows package descriptions and also offers to run an install command for you.

demo

The name Tii is an acronym for "Then Install It", which is what you'll probably say when shown "Command not found".

Installing

As of now, only macOS is supported

brew install quackduck/tap/tii

Usage, environment and files

Tii will be automatically triggered if a command is not found and so you usually do not need to directly interact with it.

Usage: tii [--help/-h | --version/-v | --refresh-cache/-r | <command>]

Examples:
   tii fish
   tii cowsay
   tii --help

Environment:
   TII_DISABLE_INTERACTIVE: If this variable is set to "true", Tii will
      disable interactive output (prompting for confirmation) and not install
      any packages.
   TII_AUTO_INSTALL_EXACT_MATCHES: If this variable is set to "true", Tii will
      automatically install exact matches without prompting for confirmation

Files:
   $XDG_DATA_HOME/tii: used to cache package list info. If $XDG_DATA_HOME is
      not set, ~/.local/share is used instead. Refresh the cache using the
      --refresh-cache option.

Uninstalling

If you have issues with Tii, head over to issues.

You can uninstall with:

brew uninstall tii

Here's a list of all the files Tii uses:

/usr/local/bin/tii
/usr/local/share/fish/vendor_functions.d/tii_on_command_not_found.fish
/etc/profile.d/tii_on_command_not_found.sh
$XDG_DATA_HOME/tii or ~/.local/share/tii

Any other business

Have a question, idea or just want to share something? Head over to Discussions