summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCraig Jennings <c@cjennings.net>2025-05-07 21:40:24 -0500
committerCraig Jennings <c@cjennings.net>2025-05-07 21:40:24 -0500
commit8926753e376078cfcb7f9b7a98e36b1eea8010bf (patch)
tree26c2b07b1fb2cf41c34d1ab722761507e42b4d86
parent7fa458d5ac88fc608a7028f3e1ec0703806a00b3 (diff)
Fixing sed statement in sudo script
-rwxr-xr-xroot_scripts/sudo_install_config.sh5
1 files changed, 3 insertions, 2 deletions
diff --git a/root_scripts/sudo_install_config.sh b/root_scripts/sudo_install_config.sh
index 2f1ec3c..c4b7730 100755
--- a/root_scripts/sudo_install_config.sh
+++ b/root_scripts/sudo_install_config.sh
@@ -14,6 +14,7 @@ pkg install -y sudo
# backup original file
cp /usr/local/etc/sudoers /usr/local/etc/sudoers.orig
-set 's
-
+sed 's/^# *%wheel ALL=(ALL:ALL) NOPASSWD: ALL/%wheel ALL=(ALL:ALL) NOPASSWD: ALL/' \
+/usr/local/etc/sudoers > /usr/local/etc/sudoers.tmp
+visudo -c -f /usr/local/etc/sudoers.tmp && mv /usr/local/etc/sudoers.tmp /usr/local/etc/sudoers