GNU/Linux Command – YES

yes — Print a string until interrupted

Summary :
It prints the command line arguments, separated by spaces and followed by a newline, forever until it is killed. ‘yes’ can be used to feeds a continuous string of the character to another process and create dummy process for learning the process control.

Example:
$ yes -- Prints 'y' followed by a newline until killed. $ yes Bharathi -- Prints 'Bharathi' followed by a newlineuntil killed. $ yes `cat myfile` -- Print myfile content until killed. $ yes | fsck /dev/hda1 -- Runs fsck non-interactively. $ yes | rm -r mydir -- Same effect as rm -rf mydir. $ yes > /dev/null & -- Dummy process.
Read : man yes

Advertisements
Tagged with: ,
Posted in Uncategorized

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: