문제

Is there are any convention/agreement about bash commands/scripts naming?

Especially about user-defined commands/scripts.

도움이 되었습니까?

해결책

From the POSIX shell guidelines for utility syntax:

Guideline 2: Utility names should include lowercase letters (the lower character classification) and digits only from the portable character set.

다른 팁

All standard command tend to be lower-case (with X and a few related utilities being the only notable exceptions that come to mind, but these are seldom invoked from the command line directly). This is quite obviously convenient: a lower-case character is just one keystroke while uppercase takes two at the same time and thus is much more cumbersome to type. This is somewhat alleviated by tab completion but nonetheless, using upper case in shell commands stands out and doesn't fit the UNIX conventions too well.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top