简体   繁体   中英

Auto suggestion in Commands in command line

I typed git s an pressed tab in ubuntu terminal and It shows git's sub-commands given below:

test: git s <tab>
shortlog  show  show-branch   stage stash status submodule

How is It happening? Auto suggestion for files is usual one. How can implement it for a command with subcommands?

An introduction to bash completion

This will give you idea about auto completion in shells like Bash.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM