
system.pl -- SICStus-3 library system
- To be done
- - This library is incomplete
environ(?Name, ?Value) is nondet- True if Value an atom associated with the environment variable
Name.
- To be done
- - Mode -Name is not supported
exec(+Command, +Streams, -PID)- SICStus 3 compatible implementation of exec/3 on top of the
SICStus 4 compatible process_create/3.
- bug
- - The SICStus version for Windows seems to hand Command
directly to CreateProcess(). We hand it to
%COMSPEC% /s /c "Command"
In case of conflict, it is adviced to use
process_create/3
wait(+PID, -Status)- Wait for processes created using exec/3.
- See also
- - exec/3
pid(-PID)- Process ID of the current process.
- Compatibility
- - sicstus.
now(-When) is det- Unify when with the current time-stamp
- Compatibility
- - sicstus
datime(+When, -Datime) is det- True when Datime is a datime/6 record that reflects the time
stamp When.
- Compatibility
- - sicstus
datime(-Datime) is det- Unifies Datime with the current date and time as a datime/6
record of the form
datime(Year,Month,Day,Hour,Min,Sec)
. All
fields are integers.
- Compatibility
- - sicstus
system
system(+Command)
system(+Command, -Status)- Synomyms for shell/0, shell/1 and shell/2.
- Compatibility
- - sicstus.
popen(+Command, +Mode, ?Stream)-
- Compatibility
- - sicstus
host_name(-HostName)-
- See also
- - gethostname/1
- Compatibility
- - sicstus
mktemp(+Template, -File) is det- Interface to the Unix function. This emulation uses
tmp_file/2 and ignores Template.
- deprecated
- - This interface is a security-risc. Use
tmp_file_stream/3.
- Compatibility
- - sicstus
tmpnam(-FileName)- Interface to
tmpnam()
. This emulation uses tmp_file/2.
- deprecated
- - This interface is a security-risc. Use
tmp_file_stream/3.
- Compatibility
- - sicstus
file_exists(+FileName) is semidet- True if a file named FileName exists.
- Compatibility
- - sicstus
system
system(+Command)
system(+Command, -Status)- Synomyms for shell/0, shell/1 and shell/2.
- Compatibility
- - sicstus.
system
system(+Command)
system(+Command, -Status)- Synomyms for shell/0, shell/1 and shell/2.
- Compatibility
- - sicstus.
Re-exported predicates
The following predicates are re-exported from other modules
shell- Execute an interactive shell. The following options are tried to
find a suitable shell command:
- The Prolog flag
shell
- The environment variable
$SHELL
- The Prolog flag
posix_shell
- The environment variable
%comspec%
(Windows only)
- Errors
- -
existence_error(config, shell)
if no suitable shell can be
found.
Undocumented predicates
The following predicates are exported, but not or incorrectly documented.
- rename_file(Arg1, Arg2)
shell(Arg1)
- sleep(Arg1)
- shell(Arg1, Arg2)
- make_directory(Arg1)
- delete_file(Arg1)
working_directory(Arg1, Arg2)