aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChong Yidong2009-07-18 04:42:25 +0000
committerChong Yidong2009-07-18 04:42:25 +0000
commit0999039ce4368f5c9db46f8202582eaace0cdbb4 (patch)
treedb587d4a1925bfedf71224d4cefcea789fb7a02f
parent0013b70f1d9d20073573c7f2c6d0d3dacc8b7270 (diff)
downloademacs-0999039ce4368f5c9db46f8202582eaace0cdbb4.tar.gz
emacs-0999039ce4368f5c9db46f8202582eaace0cdbb4.zip
* processes.texi (Shell Arguments): Copyedits.
-rw-r--r--doc/lispref/ChangeLog4
-rw-r--r--doc/lispref/processes.texi27
2 files changed, 17 insertions, 14 deletions
diff --git a/doc/lispref/ChangeLog b/doc/lispref/ChangeLog
index 856533ee45b..2de34f9997f 100644
--- a/doc/lispref/ChangeLog
+++ b/doc/lispref/ChangeLog
@@ -1,3 +1,7 @@
12009-07-18 Chong Yidong <cyd@stupidchicken.com>
2
3 * processes.texi (Shell Arguments): Copyedits.
4
12009-07-18 Glenn Morris <rgm@gnu.org> 52009-07-18 Glenn Morris <rgm@gnu.org>
2 6
3 * loading.texi (Repeated Loading): Fix typo. 7 * loading.texi (Repeated Loading): Fix typo.
diff --git a/doc/lispref/processes.texi b/doc/lispref/processes.texi
index b0d420ef07c..b80b49f38cb 100644
--- a/doc/lispref/processes.texi
+++ b/doc/lispref/processes.texi
@@ -195,33 +195,32 @@ a shell command:
195@end defun 195@end defun
196 196
197@cindex quoting and unquoting shell command line 197@cindex quoting and unquoting shell command line
198 The following two functions help creating shell commands from 198 The following two functions are useful for creating shell commands
199individual argument strings and taking shell command lines apart into 199from individual argument strings, and taking shell command lines apart
200individual arguments. 200into individual arguments.
201 201
202@defun split-string-and-unquote string &optional separators 202@defun split-string-and-unquote string &optional separators
203This function splits @var{string} into substrings at matches for the 203This function splits @var{string} into substrings at matches for the
204regular expression @var{separators}, like @code{split-string} does 204regular expression @var{separators}, like @code{split-string} does
205(@pxref{Creating Strings}), but it additionally removes quoting from 205(@pxref{Creating Strings}); in addition, it removes quoting from the
206the substrings. It then makes a list of the substrings and returns 206substrings. It then makes a list of the substrings and returns it.
207it.
208 207
209If @var{separators} is omitted or @code{nil}, it defaults to 208If @var{separators} is omitted or @code{nil}, it defaults to
210@code{"\\s-+"}, which is a regular expression that matches one or more 209@code{"\\s-+"}, which is a regular expression that matches one or more
211characters with whitespace syntax (@pxref{Syntax Class Table}). 210characters with whitespace syntax (@pxref{Syntax Class Table}).
212 211
213The quoting this function supports is of 2 styles: by enclosing a 212This function performs two types of quoting: enclosing a whole string
214whole string in double quotes @code{"@dots{}"}, or by quoting 213in double quotes @code{"@dots{}"}, and quoting individual characters
215individual characters with a backslash escape @samp{\}. The latter is 214with a backslash escape @samp{\}. The latter is also used in Lisp
216also used in Lisp strings, so this function can handle those as well. 215strings, so this function can handle those as well.
217@end defun 216@end defun
218 217
219@defun combine-and-quote-strings list-of-strings &optional separator 218@defun combine-and-quote-strings list-of-strings &optional separator
220This function concatenates @var{list-of-strings} into a single string, 219This function concatenates @var{list-of-strings} into a single string,
221quoting each string in the list that needs quoting as it goes. It 220quoting each string as necessary. It also sticks the @var{separator}
222also sticks the @var{separator} string in between each pair of strings 221string between each pair of strings; if @var{separator} is omitted or
223in the result, and returns that result. If @var{separator} is omitted 222@code{nil}, it defaults to @code{" "}. The return value is the
224or @code{nil}, it defaults to a blank @code{" "}. 223resulting string.
225 224
226The strings in @var{list-of-strings} that need quoting are those that 225The strings in @var{list-of-strings} that need quoting are those that
227include @var{separator} as their substring. Quoting a string encloses 226include @var{separator} as their substring. Quoting a string encloses