Make your own manual. [Linux] [man]

environment

let's do it

Start the terminal with Ctrl + Alt + t. Enter the following command. (manl can be anything)

$ mkdir man 
$ cd man 
$ mkdir manl 
$ cd manl

Then write the contents of man with a text editor. There is a format like the markdown of qiita.

How to make your own command

I created my own command --qiita

Write a man for your own command.

Contents of self-made command:

lock.sh


#!/bin/sh
#chmod=Change access rights
#a-rwx=Remove read / write / execute permissions for everyone
#$1=Get arguments(argument=a-File name to rwx)
chmod a-rwx $1

lock.l


.\"This line is a comment.
.TH lOCK
.SH name
.\"Write a name and a one-word explanation.
lock \-Delete file read / write access rights
.SH format
.B lock 
[file name]
.SH description
.\"Write a description.
lock is a text file or image file,Remove access privileges such as.

.\"Write the author and copyright.
.SH author
Author ichiri sato.
.SH copyright
(c) 2020 ichiri sato. 

Use the -M argument to display your own man.

$ man -M ~/man lock.l

Display result


lOCK()                                                                 lOCK()

name
       lock -Delete file read / write access rights

Format
       lock [file name]

Description
lock is a text file or image file,Remove access privileges such as.

author
Author ichiri sato.

Copyright
       (c) 2020 ichiri sato.
                                                                       lOCK()

~
~
~
~
~
(abridgement)

Reference article

-To create your own man page- @ IT

Recommended Posts

Make your own manual. [Linux] [man]
[Python] Make your own LINE bot
Create your own Linux commands in Python
Make your own PC for deep learning
Try to make your own AWS-SDK with bash
Linux C / C ++ Build your own library creation environment
Make your own module quickly with setuptools (python)
Make your own music player with Bottle0.13 + jPlayer2.5!
Take your own peak memory usage on Linux & Python
Make your cursor a photo of your choice on Linux
Make Jupyter Notebook your own: Change background and icons
Learn "x86 architecture learned with your own emulator" with Manjaro (Linux)
Let's make a number guessing game in your own language!
Install Linux on your Chromebox
Create your own Django middleware
Make Amazon Linux 2 (CentOS) GUI
Japanese translation of Linux manual
Make the theme of Pythonista 3 like Monokai (how to make your own theme)
Make your own VPC with a Single Public Subnet Only with boto
How to make your own domain site with heroku (free plan)