All Samples(12321) | Call(12231) | Derive(0) | Import(90)
unlink(path) Remove a file (same as remove(path)).
src/d/u/dutils-0.0.10/dutils/sample/path.py dutils(Download)
def unlink(self):
os.unlink(self)
# --- Links
if hasattr(os, 'link'):
src/e/v/evserver-HEAD/evserver/examples/comet.py evserver(Download)
os.close(fd)
except GeneratorExit:
pass
os.unlink(fname)
return iterator()
class cometread_longpoll:
os.close(fd)
except GeneratorExit:
pass
os.unlink(fname)
return iterator()
src/f/u/fuse-python-0.2/example/xmp.py fuse-python(Download)
def unlink(self, path):
os.unlink("." + path)
def rmdir(self, path):
os.rmdir("." + path)
def symlink(self, path, path1):
src/p/y/python-cookbook-HEAD/cb2_examples/cb2_10_6_sol_1.py python-cookbook(Download)
if x:
raise RuntimeError, "Can't run %s %s (%s)" % (editor, temp_filename, x)
result = open(temp_filename).read()
os.unlink(temp_filename)
return result
if __name__=='__main__':
text = edited_text('''Edit this text a little,
src/m/a/matplotlib-HEAD/matplotlib/examples/tests/backend_driver.py matplotlib(Download)
if os.path.exists(path):
import glob
for fname in os.listdir(path):
os.unlink(os.path.join(path,fname))
else:
os.mkdir(backend)
failures = []
src/m/a/matplotlib-HEAD/examples/tests/backend_driver.py matplotlib(Download)
if os.path.exists(path):
import glob
for fname in os.listdir(path):
os.unlink(os.path.join(path,fname))
else:
os.mkdir(backend)
failures = []
src/n/o/notmm-0.4.1/examples/lib/l10n/bin/make-messages.py notmm(Download)
potfile = os.path.join(basedir, '%s.pot' % domain)
if os.path.exists(potfile):
os.unlink(potfile)
all_files = []
for (dirpath, dirnames, filenames) in os.walk("."):
msgs = msgs.replace(old, new)
if msgs:
open(potfile, 'ab').write(msgs)
os.unlink(os.path.join(dirpath, thefile))
elif domain == 'django' and (file.endswith('.py') or file.endswith('.html') or file.endswith('.txt') or file.endswith('.rml')):
thefile = file
if file.endswith('.html') or file.endswith('.txt') or file.endswith('.rml'):
if msgs:
open(potfile, 'ab').write(msgs)
if thefile != file:
os.unlink(os.path.join(dirpath, thefile))
if os.path.exists(potfile):
(stdin, stdout, stderr) = os.popen3('msguniq --to-code=utf-8 "%s"' % potfile, 'b')
print errors
sys.exit(8)
open(pofile, 'wb').write(msgs)
os.unlink(potfile)
if __name__ == "__main__":
make_messages()
src/m/a/Matplotlib--JJ-s-dev-HEAD/examples/tests/backend_driver.py Matplotlib--JJ-s-dev(Download)
if os.path.exists(path):
import glob
for fname in os.listdir(path):
os.unlink(os.path.join(path,fname))
else:
os.mkdir(backend)
failures = []
src/v/i/vizstack-HEAD/trunk/share/samples/xconfig_generation/2gpu.py vizstack(Download)
print >>sys.stderr, "Failed to generate X configuration file." # Remove our temporary file os.unlink(tempFile) # Done! sys.exit(ret)
src/v/i/vizstack-HEAD/trunk/share/samples/xconfig_generation/1gpu-1output.py vizstack(Download)
print >>sys.stderr, "Failed to generate X configuration file." # Remove our temporary file os.unlink(tempFile) # Done! sys.exit(ret)
1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 Next