Change chdir of sudo installation properly
This commit is contained in:
parent
ca17ea2fa4
commit
5785856d45
1 changed files with 4 additions and 0 deletions
|
@ -1,5 +1,7 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# Elevate script
|
# Elevate script
|
||||||
|
pushd "${BASH_SOURCE%/*}" > /dev/null;
|
||||||
|
|
||||||
if [ ! "$UID" -eq 0 ]
|
if [ ! "$UID" -eq 0 ]
|
||||||
then
|
then
|
||||||
sudo bash "$BASH_SOURCE";
|
sudo bash "$BASH_SOURCE";
|
||||||
|
@ -7,3 +9,5 @@ else
|
||||||
pacman --noconfirm -Syu sudo;
|
pacman --noconfirm -Syu sudo;
|
||||||
source "../../Config/sudo/install.sh";
|
source "../../Config/sudo/install.sh";
|
||||||
fi;
|
fi;
|
||||||
|
|
||||||
|
popd > /dev/null;
|
||||||
|
|
Loading…
Reference in a new issue