Easy steps to install trash-cli package on Mac

Package Information:

Application Name – trash-cli
What is trash-cli – Works on macOS (10.12+), Linux, and Windows (8+). In contrast to rm which is dangerous and permanently delete files, this only moves them to the trash, which is much safer and reversible.
Use of trash-cli – Command-line interface to the freedesktop.org trashcan
URL – https://github.com/andreafrancia/trash-cli

Installation Steps:

  1. Open Terminal using Spotlight search by pressing  <command+space>. Type terminal and hit  Enter  key.
  2. spotlight search terminal

  3. Now, run following command to install homebrew (brew)
  4. ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" < /dev/null 2> /dev/null

    Homebrew Install Command Screenshot

  5. Install trash-cli using brew
    brew install trash-cli

trash-cli  is ready to use now!