[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Guile-commits] 05/10: doc: Add missing canonicalize-path documentation.
From: |
Ludovic Courtès |
Subject: |
[Guile-commits] 05/10: doc: Add missing canonicalize-path documentation. |
Date: |
Wed, 17 Jun 2020 18:32:11 -0400 (EDT) |
civodul pushed a commit to branch master
in repository guile.
commit 5fbf5c10fc3054d788a006f619105a8c60741319
Author: Ricardo G. Herdt <r.herdt@posteo.de>
AuthorDate: Sat May 30 22:50:16 2020 +0200
doc: Add missing canonicalize-path documentation.
The documentation is copied over from libguile/filesys.c. I just added
"(absolute)" to the text to help users finding it, since this term is
more common in other languages.
* doc/ref/posix.texi (File System): Document it.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
---
doc/ref/posix.texi | 15 +++++++++++++++
1 file changed, 15 insertions(+)
diff --git a/doc/ref/posix.texi b/doc/ref/posix.texi
index b2be9d7..f34c522 100644
--- a/doc/ref/posix.texi
+++ b/doc/ref/posix.texi
@@ -1040,6 +1040,21 @@ If @var{suffix} is provided, and is equal to the end of
@end lisp
@end deffn
+@deffn {Scheme Procedure} canonicalize-path path
+@deffnx {C Function} scm_canonicalize_path (path)
+Return the canonical (absolute) path of @var{path}.
+A canonical path has no @code{.} or @code{..} components,
+nor any repeated path separators (@code{/}) nor symlinks.
+
+Raises an error if any component of @var{path} does not
+exist.
+
+@lisp
+(canonicalize-path "test.xml")
+@result{} "/tmp/test.xml"
+@end lisp
+@end deffn
+
@deffn {Scheme Procedure} file-exists? filename
Return @code{#t} if the file named @var{filename} exists, @code{#f} if
not.
- [Guile-commits] branch master updated (2e2e13c -> dfca16f), Ludovic Courtès, 2020/06/17
- [Guile-commits] 01/10: srfi-1: Rewrite 'find' in Scheme., Ludovic Courtès, 2020/06/17
- [Guile-commits] 03/10: srfi-1: Rewrite 'assoc' in Scheme., Ludovic Courtès, 2020/06/17
- [Guile-commits] 02/10: srfi-1: Rewrite 'find-tail' in Scheme., Ludovic Courtès, 2020/06/17
- [Guile-commits] 04/10: read: Use "invalid" rather than "illegal"., Ludovic Courtès, 2020/06/17
- [Guile-commits] 05/10: doc: Add missing canonicalize-path documentation.,
Ludovic Courtès <=
- [Guile-commits] 07/10: doc: Fix minor typo in the HTTP headers documentation., Ludovic Courtès, 2020/06/17
- [Guile-commits] 10/10: doc: Mention (ice-9 time) module path., Ludovic Courtès, 2020/06/17
- [Guile-commits] 08/10: doc: Improve content-range HTTP header documentation., Ludovic Courtès, 2020/06/17
- [Guile-commits] 09/10: doc: Document default delimiter of string-join., Ludovic Courtès, 2020/06/17
- [Guile-commits] 06/10: texinfo: Add basic support for @w{...}., Ludovic Courtès, 2020/06/17