Returns the contents of a file as a string.
hcl
file-string file &key length external-format => string
file⇩ |
A pathname designator. |
length⇩ |
An integer or nil (the default). |
external-format⇩ |
An external format specification. |
string |
A string. |
The function file-string
returns the entire contents of file (if length is nil
), or the first length characters, as a string.
external-format is interpreted as for open. The default value is :default
.
CL-USER 26 > file-string "configure.lisp" :length 18 ";; -*- Mode: Lisp;"
LispWorks® User Guide and Reference Manual - 01 Dec 2021 19:30:35