Opened 5 years ago

Last modified 5 years ago

#58739 closed defect

error getting working directory — at Version 1

Reported by: ParityError Owned by:
Priority: Normal Milestone:
Component: base Version: 2.5.4
Keywords: Cc:
Port:

Description (last modified by ParityError)

If you're in a directory that no longer exists and attempt to run any commands relating to MacPorts you'll get an error:

$ cd ~/desktop
$ mkdir test
$ cd $_
$ rm -rf ../test
$ port search xorg-server
error getting working directory name: no such file or directory
    while executing
"pwd"
    invoked from within
"set current_portdir [pwd]"
    (file "/opt/local/bin/port" line 5725)

Yes, it's a strange to remove a directory that you are pwd, but maybe MacPorts should have some type of check in that circumstance?

Change History (1)

comment:1 Changed 5 years ago by ParityError

Description: modified (diff)
Note: See TracTickets for help on using tickets.