Create an empty file. If the file already exists, truncate it.
(filename)
| 600 | |
| 601 | |
| 602 | def create_empty_file(filename): |
| 603 | """Create an empty file. If the file already exists, truncate it.""" |
| 604 | fd = os.open(filename, os.O_WRONLY | os.O_CREAT | os.O_TRUNC) |
| 605 | os.close(fd) |
| 606 | |
| 607 | |
| 608 | @contextlib.contextmanager |
searching dependent graphs…