Handbook
Glossary
set-current-directory ( path -- )
Factor handbook
»
Input and output
»
Directory manipulation
»
Current working directory
Prev:
current-directory
Next:
with-directory ( path quot -- )
Vocabulary
io
.
directories
Inputs
path
a pathname string
Outputs
None
Word description
Changes the
current-directory
variable.
If
path
is relative, it is first resolved relative to the current directory. If
path
is absolute, it becomes the new current directory.
See also
cd
,
cwd
,
current-directory
,
with-directory
Definition
USING:
io.pathnames
namespaces
;
IN:
io.directories
:
set-current-directory
( path -- )
absolute-path
current-directory
set
;