Tidying up Python

Chris Jones jonesc at hep.phy.cam.ac.uk
Fri Jul 11 10:55:50 UTC 2025


>> Prefix those commands with "sudo" for normal root MacPorts installations.
> 
> Well, I'm running under "sudo bash" under my admin account to avoid
> having to prefix every admin task w/ "sudo"

That is in general dangerous and not to be recommended.

The better way is to configure your sudoers list to allow your regular 
user account to run the port command through sudo without requiring a 
password. Its trivial to do and there are plenty examples on the web on 
how to do it. e.g.

<https://askubuntu.com/questions/159007/how-do-i-run-specific-sudo-commands-without-a-password>

This is way better than doing everything in a `sudo bash` shell as 
*only* that one command will run without requiring a password. Whereas 
what you are doing everything you type in that terminal session, good or 
bad, will run with sudo privileges.

Chris


More information about the macports-users mailing list