mkdir.py 229 B

12345678910111213
  1. #!/usr/bin/env python
  2. import os
  3. import sys
  4. def mkdir_p(directory):
  5. if not os.path.exists(directory):
  6. os.makedirs(directory)
  7. if __name__ == "__main__":
  8. for directory in sys.argv[1:]:
  9. mkdir_p(directory)