Home | 简体中文 | 繁体中文 | 杂文 | Github | 知乎专栏 | 51CTO学院 | CSDN程序员研修院 | OSChina 博客 | 腾讯云社区 | 阿里云栖社区 | Facebook | Linkedin | Youtube | 打赏(Donations) | About
知乎专栏多维度架构

第 22 章 Shell 命令

目录

22.1. Help Commands
22.1.1. man - an interface to the on-line reference manuals
22.2. getconf - Query system configuration variables
22.3. test 命令
22.3.1. 判断目录
22.4. 目录和文件
22.4.1. dirname
22.4.2. filename
22.4.3. test - check file types and compare values
22.4.4. file — determine file type
22.4.5. stat
22.4.6. mkdir - make directories
22.4.7. rename
22.4.8. touch
22.4.9. truncate
22.4.10. ls - list directory contents
22.4.11. cp - copy files and directories
22.4.12. rm - remove files or directories
22.4.13. df - report file system disk space usage
22.4.14. du - estimate file space usage
22.4.15. tac - concatenate and print files in reverse
22.4.16. split - split a file into pieces
22.4.17. find - search for files in a directory hierarchy
22.5. package / compress and decompress
22.5.1. tar — The GNU version of the tar archiving utility
22.5.2. cpio - copy files to and from archives
22.5.3. gzip
22.5.4. zip, zipcloak, zipnote, zipsplit - package and compress (archive) files
22.5.5. bzip2, bunzip2 - a block-sorting file compressor
22.5.6. RAR
22.5.7. 7-Zip
22.5.8. RAR
22.5.9. xz, unxz, xzcat, lzma, unlzma, lzcat - Compress or decompress .xz and .lzma files
22.6. 日期和时间
22.6.1. 日期格式
22.6.2. -d --date=
22.6.3. 时间戳
22.6.4. RFC 2822
22.6.5. UTC
22.6.6. 字符串转日期
22.7. 数值与运算
22.7.1. 数值运算
22.7.2. seq - print a sequence of numbers
22.7.3. bc - An arbitrary precision calculator language
22.8. 文本处理
22.8.1. iconv - Convert encoding of given files from one encoding to another
22.8.2. 字符串处理命令expr
22.8.3. cat - concatenate files and print on the standard output
22.8.4. nl - number lines of files
22.8.5. tr - translate or delete characters
22.8.6. cut - remove sections from each line of files
22.8.7. printf - format and print data
22.8.8. Free `recode' converts files between various character sets and surfaces.
22.8.9. /dev/urandom 随机字符串
22.8.10. col - filter reverse line feeds from input
22.8.11. apg - generates several random passwords
22.8.12. head/tail
22.8.13. 反转字符串或文件内容
22.8.14. TAB符号与空格处理
22.8.15. grep, egrep, fgrep, rgrep - print lines matching a pattern
22.8.16. sort - sort lines of text files
22.8.17. uniq
22.8.18. awk
22.8.19. sed
22.9. 表格操作/行列转换
22.9.1. column - columnate lists
22.9.2. paste - merge lines of files
22.9.3. join
22.10. standard input/output
22.10.1. xargs - build and execute command lines from standard input
22.11. flock - manage locks from shell scripts
22.12. 进制转换 - 16进制 - 8进制 - 二进制
22.12.1. od - dump files in octal and other formats
22.12.2. hexdump, hd -- ASCII, decimal, hexadecimal, octal dump
22.12.3. xxd - make a hexdump or do the reverse.
22.12.4. binutils
22.13. 文件比较
22.13.1. diff
22.13.2. sdiff
22.13.3. diff3
22.14. ed, red - text editor
22.15. vim
22.15.1. vim 初始化
22.15.2. 查找与替换
22.15.3. 删除操作
22.15.4. 插入文件
22.15.5. 批处理
22.15.6. line()
22.15.7. set fileformat
22.15.8. 空格与TAB转换
22.16. Wget - The non-interactive network downloader.
22.16.1. Logging and input file
22.16.2. 下载相关参数
22.16.3. HTTP options (HTTP 选项)
22.16.4. Recursive download
22.16.5. --no-passive-ftp disable the "passive" transfer mode.
22.16.6. 下载一组连续的文件名
22.17. CURL - transfer a URL
22.17.1. 基本用法
22.17.2. 提交表单数据
22.17.3. 上传文件
22.17.4. connect-timeout
22.17.5. max-time
22.17.6. compressed
22.17.7. 代理服务器
22.17.8. -w, --write-out <format> 输出格式定义
22.17.9. -A/--user-agent <agent string>
22.17.10. referer
22.17.11. -v
22.17.12. -o, --output FILE Write output to <file> instead of stdout
22.17.13. -L, --location
22.17.14. -H/--header <line> Custom header to pass to server (H)
22.17.15. curl-config
22.17.16. 指定网络接口或者地址
22.17.17. Cookie 处理
22.17.18. Restful 应用 JSON 数据处理
22.17.19. 访问自签名证书
22.17.20. HTTP2
22.17.21. FAQ
22.18. expect
22.18.1. 模拟登录 telnet 获取Cisco配置
22.18.2. 模拟登录 ssh
22.18.3. SCP
22.18.4. openssl 例子
22.19. expect-lite - quick and easy command line automation tool
22.20. sshpass - noninteractive ssh password provider
22.21. Klish - Kommand Line Interface Shell (the fork of clish project)
22.21.1. 安装Klish
22.21.2. 为用户指定clish作为默认Shell
22.21.3. FAQ
22.22. Limited command Shell (lshell)
22.23. TUI
22.23.1. screen - screen manager with VT100/ANSI terminal emulation
22.23.2. tmux — terminal multiplexer
22.23.3. byobu - wrapper script for seeding a user's byobu configuration and launching a text based window manager (either screen or tmux)
22.23.4. htop - interactive process viewer
22.23.5. elinks
22.23.6. chat
22.24. jq - Command-line JSON processor
22.24.1. --raw-output
22.25. asciinema 终端录屏
22.26. parallel - build and execute shell command lines from standard input in parallel
22.27. multitail
22.28. Logging
22.28.1. logger - a shell command interface to the syslog(3) system log module
22.29. Password
22.29.1. Shadow password suite configuration.
22.29.2. newusers - update and create new users in batch
22.29.3. chpasswd - update passwords in batch mode
22.29.4. sshpass - noninteractive ssh password provider
22.30. 信息摘要
22.30.1. cksum, sum -- display file checksums and block counts
22.30.2. md5sum - compute and check MD5 message digest
22.30.3.
22.31. envsubst - substitutes environment variables in shell format strings

22.1. Help Commands

22.1.1. man - an interface to the on-line reference manuals

manpath.config
cat /etc/manpath.config
			
查看man手册位置
$ man -aw ls
/usr/share/man/man1/ls.1.gz
			
指定手册位置
man -M /home/mysql/man mysql