Source code for whisk.cd
import os
[docs]class cd:
"""
Context manager for changing the current working directory
Based on https://stackoverflow.com/questions/431684/how-do-i-change-the-working-directory-in-python/13197763#13197763
"""
def __init__(self, newPath):
self.newPath = os.path.expanduser(newPath)