Improve error message
This commit is contained in:
parent
c6bf44ccd9
commit
3ede731b6c
1 changed files with 2 additions and 2 deletions
|
|
@ -224,9 +224,9 @@ class Shell:
|
|||
# directory = self.getcwd() + "/" + directory
|
||||
directory = self.path(directory)
|
||||
if not self.exists(directory):
|
||||
raise ValueError("Directory does not exist")
|
||||
raise ValueError(f"Directory '{directory}' does not exist")
|
||||
if not self.isdir(directory):
|
||||
raise ValueError("Given location is not a directory")
|
||||
raise ValueError(f"The given location '{directory}' is not a directory")
|
||||
os.chdir(directory)
|
||||
|
||||
def pushd(self, directory):
|
||||
|
|
|
|||
Loading…
Reference in a new issue