From 7ddecde54372c25fcf526e2d24807c5dac9800aa Mon Sep 17 00:00:00 2001 From: axel Date: Tue, 20 Sep 2005 23:31:55 +1000 Subject: Add subdirectories darcs-hash:20050920133155-ac50b-9a14c6c664dd03afbe8e15e7c7998fcfb5c3c750.gz --- doc_src/while.txt | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 doc_src/while.txt (limited to 'doc_src/while.txt') diff --git a/doc_src/while.txt b/doc_src/while.txt new file mode 100644 index 00000000..3a59afc5 --- /dev/null +++ b/doc_src/while.txt @@ -0,0 +1,13 @@ +\section while while - perform a command multiple times + +\subsection while-synopsis Synopsis +while CONDITION; COMMANDS; end + +\subsection while-synopsis Synopsis +The while builtin causes fish to continually execute the command COMMANDS while the command CONDITION returns with status 0. + +\subsection while-example Example + +while test -f foo.txt; echo file exists; sleep 10; end + +causes fish to print the line 'file exists' at 10 second intervals as long as the file foo.txt exists. -- cgit v1.2.3