답변:
일부 내장 명령은 효율성을 위해 포함되며 처음에는 외부 명령으로 존재합니다. 예를 들면 다음과 같습니다.
$ type -a echo
echo is a shell builtin
echo is /bin/echo
$ type -a printf
printf is a shell builtin
printf is /usr/bin/printf
내장 및 외부 명령에 대한 자세한 분석은 Unix & Linux 에서 찾을 수 있습니다 .
듀얼 내장 / 외부 명령에 대한 도움을받는 echo
한 두 가지 선택이 있습니다. 한 가지 방법은 다음을 사용하는 것입니다 man echo
.
ECHO(1) User Commands ECHO(1)
NAME
echo - display a line of text
SYNOPSIS
echo [SHORT-OPTION]... [STRING]...
echo LONG-OPTION
DESCRIPTION
Echo the STRING(s) to standard output.
-n do not output the trailing newline
-e enable interpretation of backslash escapes
-E disable interpretation of backslash escapes (default)
--help display this help and exit
--version
output version information and exit
If -e is in effect, the following sequences are recognized:
\\ backslash
\a alert (BEL)
Manual page echo(1) line 1 (press h for help or q to quit)
그리고 당신은 입력 할 수 있습니다 :
$ help echo
echo: echo [-neE] [arg ...]
Write arguments to the standard output.
Display the ARGs, separated by a single space character and followed by a
newline, on the standard output.
Options:
-n do not append a newline
-e enable interpretation of the following backslash escapes
-E explicitly suppress interpretation of backslash escapes
`echo' interprets the following backslash-escaped characters:
\a alert (bell)
\b backspace
\c suppress further output
\e escape character
\E escape character
\f form feed
\n new line
\r carriage return
\t horizontal tab
\v vertical tab
\\ backslash
\0nnn the character whose ASCII code is NNN (octal). NNN can be
0 to 3 octal digits
\xHH the eight-bit character whose value is HH (hexadecimal). HH
can be one or two hex digits
Exit Status:
Returns success unless a write error occurs.