Add setPermissions()

This commit is contained in:
Santiago Lo Coco 2022-02-28 20:09:26 -03:00
parent 9923bfc641
commit d3ad535653
1 changed files with 7 additions and 3 deletions

View File

@ -1,13 +1,17 @@
#!/usr/bin/env bash
setPermissions() {
echo "nobody ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers
visudo -c
chmod -R a+rw .
}
runScript() {
set -euo pipefail
pacman -Syu --noconfirm base-devel
echo "nobody ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers
visudo -c
chmod -R a+rw .
setPermissions
baseDir="$PWD"
[ -n "$INPUT_PKGDIR" ] && inBaseDir=true || inBaseDir=false