This is a read-only mirror of pymolwiki.org
Difference between revisions of "System"
Jump to navigation
Jump to search
(added category label) |
m (9 revisions) |
||
(7 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
− | + | ||
− | + | The '''system''' command, executes a command in a subshell under Unix or Windows. | |
− | + | ||
===USAGE=== | ===USAGE=== | ||
− | + | <source lang="python"> | |
− | + | # execute 'command' | |
+ | system command | ||
+ | </source> | ||
+ | |||
===PYMOL API=== | ===PYMOL API=== | ||
− | + | <source lang="python"> | |
− | + | cmd.system(string command,int async=0) | |
+ | </source> | ||
+ | |||
===NOTES=== | ===NOTES=== | ||
async can only be specified from the Python level (not the command language) | async can only be specified from the Python level (not the command language) | ||
Line 16: | Line 21: | ||
[[ls]], [[cd]], [[pwd]] | [[ls]], [[cd]], [[pwd]] | ||
− | [[Category:Commands| | + | [[Category:Commands|System]] |
Latest revision as of 03:36, 28 March 2014
The system command, executes a command in a subshell under Unix or Windows.
USAGE
# execute 'command'
system command
PYMOL API
cmd.system(string command,int async=0)
NOTES
async can only be specified from the Python level (not the command language)
- if async is 0 (default), then the result code from "system" is returned in r
- if async is 1, then the command is run in a separate thread whose object is returned