1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 Next
1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 Next
All Samples(14089) | Call(0) | Derive(0) | Import(14089)
Common operations on Posix pathnames. Instead of importing this module directly, import os and refer to this module as os.path. The "os.path" name is an alias for this module on Posix systems; on other systems (e.g. Mac, Windows), os.path provides the same operations in a manner specific to that platform, and is an alias to another module (e.g. macpath, ntpath). Some of this can actually be useful on non-Posix systems too, e.g. for manipulation of the pathname component of URLs.
All Samples(17050) | Call(16291) | Derive(0) | Import(759)
listdir(path) -> list_of_strings
Return a list containing the names of the entries in the directory.
path: path of directory to list
The list is in arbitrary order. It does not include the special
entries '.' and '..' even if they are present in the directory.
All Samples(16184) | Call(15625) | Derive(0) | Import(559)
remove(path) Remove a file (same as unlink(path)).
All Samples(13012) | Call(12477) | Derive(0) | Import(535)
system(command) -> exit_status Execute the command (a string) in a subshell.
All Samples(12321) | Call(12231) | Derive(0) | Import(90)
unlink(path) Remove a file (same as remove(path)).
All Samples(12248) | Call(12028) | Derive(0) | Import(220)
getcwd() -> path Return a string representing the current working directory.
All Samples(11320) | Call(11076) | Derive(0) | Import(244)
mkdir(path [, mode=0777]) Create a directory.
All Samples(10523) | Call(10413) | Derive(0) | Import(110)
chdir(path) Change the current working directory to the specified path.
All Samples(8828) | Call(8255) | Derive(0) | Import(573)
makedirs(path [, mode=0777]) Super-mkdir; create a leaf directory and all intermediate ones. Works like mkdir, except that any intermediate path segment (not just the rightmost) will be created if it does not exist. This is recursive.
All Samples(6609) | Call(6580) | Derive(0) | Import(29)
close(fd) Close a file descriptor (for low level IO).
All Samples(6565) | Call(6355) | Derive(0) | Import(210)
stat(path) -> stat result Perform a stat system call on the given path.
All Samples(5234) | Call(4906) | Derive(0) | Import(328)
rename(old, new) Rename a file or directory.
All Samples(4374) | Call(4302) | Derive(0) | Import(72)
Directory tree generator.
For each directory in the directory tree rooted at top (including top
itself, but excluding '.' and '..'), yields a 3-tuple
dirpath, dirnames, filenames
dirpath is a string, the path to the directory. dirnames is a list of
the names of the subdirectories in dirpath (excluding '.' and '..').
filenames is a list of the names of the non-directory files in dirpath.(more...)
All Samples(3838) | Call(3789) | Derive(0) | Import(49)
access(path, mode) -> True if granted, False otherwise Use the real uid/gid to test for access to a path. Note that most operations will use the effective uid/gid, therefore this routine can be used in a suid/sgid environment to test if the invoking user has the specified access to the path. The mode argument can be F_OK to test existence, or the inclusive-OR of R_OK, W_OK, and X_OK.
All Samples(3393) | Call(3248) | Derive(0) | Import(145)
popen(command [, mode='r' [, bufsize]]) -> pipe Open a pipe to/from a command returning a file object.
All Samples(3193) | Call(3065) | Derive(0) | Import(128)
getpid() -> pid Return the current process id
All Samples(3054) | Call(2989) | Derive(0) | Import(65)
chmod(path, mode) Change the access permissions of a file.
All Samples(2541) | Call(2493) | Derive(0) | Import(48)
Get an environment variable, return None if it doesn't exist. The optional second argument can specify an alternate default.
1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 Next