GNU Core Utilities - Wikipedia, the free encyclopedia
GNU Core Utilities - Wikipedia, the free encyclopedia
yes (Unix) - Wikipedia, the free encyclopedia
yes
can be used to send an affirmative (or negative; e.g. yes n) response to any command that would otherwise request one, and thereby causing the command to run non-interactively.
This usage may be obsolete today, as most commands that would request response from the user have either a 'force' option (e.g., rm -f) or an 'assume-yes' option (e.g., apt-get -y in Debian).
As an example, the following:
rm -f *.txt
is equivalent to
yes | rm *.txt
沒有留言:
張貼留言