Closed theboyler closed 2 years ago
This question should be addressed upstream (Homebrew), since brew cu
is just a wrapper plugin to a brew
and use the very same brew
commands during actual casks upgrade.
Nevertheless, I can say that a lot of swords were crossed on this topic and there is no easy yet secure solution to solve this problem. A risky one may completely disable password prompts in CLI upon escalating privileges to a superuser on his system by just one line in sudoers
file. I will not give a final solution for this approach, you may google it if you want. This is a very bad practice and security hole, especially for the huge amount of dumb users that just blindly copy-paste any commands they find in the wild interwebs.
Thx @yurikoles for jumping in. And he is completely right, currently (except making passwordless sudo) there isn't a way for making this possible. Also saving your sudo password in plain text anywhere on your computer isn't probably a good idea as well 🙂
I'll close this issue, if anyone has anything to add, feel free to reopen it.
So, when I use CU in terminal, some apps require a password to be entered as part of the installation process for updates; this prevents having CU run automatically via Launchd or by an Alfred workflow, say, because the process won't complete without the user intervention, which the user won't know about or be able to complete because they're not using an interactive process like Terminal where they a) know about the need to enter a password and b) have the means to enter it.
Is this something that can be overridden, whereby a password is entered into a local file and used by CU when homebrew prompts for it for app installs?