BlogBlog ÜbersichtjailscriptportsoptFreeBSDLinksThermoskanneKontakt

Alle Fragen eines Programms mit Ja beantworten

Führt man ein Programm aus, welches Eingaben des Benutzers erwartet, so kann dieses nicht ohne weiteres unbeaufsichtigt ausgeführt werden:

# programm
[...]
Do you want to continue [y/n]?
Are you sure [y/n]?
[...]

Können jedoch alle Fragen mit y beantwortet werden, so können diese automatisch mit yes beantwortet werden:

# yes | programm

Sollen alle Fragen zum Beispiel mit n beantwortet werden, so können diese auch mit Hilfe von yes beantwortet werden:

# yes n | programm

Auf FreeBSD ist yes standardmässig im Basissystem vorhanden. Mehr Informationen zu yes findet man in der Manpage yes(1).

Comments (0)  Permalink

Comments

add a comment

The Trackback URL to this post is:
http://www.chruetertee.ch/blog/plugin=trackback(1713).xml
Trackbacks are moderated.

This blog is gravatar enabled.
Your email adress will never be published.
Comment spam will be deleted!

Name*
E-Mail
For Spammers Only
URL
Comment*
Notify me via E-Mail when new comments are made to this entry
Remember me (needs cookies)