Skip to content

shinokada/manop

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 

Repository files navigation

Buy Me a Coffee at ko-fi.com

manop for macOS/Linux

Overview

Manop is a simple Bash script that display a command description and options from Man page or help on macOS/Linux.

Medium article

Requirements

UNIX-lie (Tested on Ubuntu and MacOS.)

Installation

For macOS/Linux

awesome install manop

Homebrew

If you installed Homebrew on your macOS, you can run:

brew tap shinokada/manop && brew install manop

Linux/Debian/Ubuntu

Download the latest deb file from the release page.

sudo apt install manop_XXXXXXX.deb

Replace XXXXXXX with the downloaded version.

Manual

I keep manop in the /home/shin/awesome directory:

mkdir /home/your-username/awesome
cd /home/your-username/awesome
git clone https://github.com/shinokada/manop.git

Create the ~/bin directory:

mkdir ~/bin

Check if /home/your-username/bin in the PATH variable:

echo $PATH
/home/your-username/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin

If not add the /home/your-username/bin directory to the ~/.bashrc file.

export PATH="/home/your-username/bin:$PATH"

Source the ~/.bashrc file and check it again:

source ~/.bashrc
echo $PATH

Add a symlink:

ln -s /home/your-username/awesome/manop/manop ~/bin/manop

Check if the symlink is working:

which manop
/home/your-username/bin/manop
manop -h
Name:
=====
manop
...

Uninstallation

# brew
brew unistall manop
# awesome
awesome rm manop

Usage

manop [ -t | -h | -v][ command name ][ command option ] -t | --trim Trim spaces -v | --version Show version -h | --help Help

Examples

Print wget -b option description:

manop wget -b

Print the ls command description:

manop ls

Print a builtin command description:

manop cd

Print the builtin cd -e option description:

manop cd -e

The outputs may have spaces. You can trim spaces using -t flag:

manop grep -b
     -b, --byte-offset
             The offset in bytes of a matched pattern is displayed in front of
             the respective matched line.

manop -t grep -b
-b, --byte-offset
The offset in bytes of a matched pattern is displayed in front of
the respective matched line.

To display builtin command help use help:

help cd

Author

Shinichi Okada

License

Please see license.

About

Manop is a simple Bash script that displays a command description and options from the Man page or help on macOS/Linux.

Topics

Resources

License

Code of conduct

Stars

Watchers

Forks

Packages

No packages published

Languages