privelages fix on bashrc

This commit is contained in:
Ryan Bakkes 2022-10-05 00:58:02 +02:00
parent f0a9c874ed
commit 6a7134147e

View File

@ -1,3 +1,5 @@
#!/bin/bash -i
# Get install file
wget https://dl.pstmn.io/download/latest/linux64
@ -6,14 +8,13 @@ sudo tar -xvf linux64 -C /usr/bin
# export postman to env table
if [[ $(which zsh) == "/usr/bin/zsh" ]]; then
echo '# Postman path' >> ~/.tempzshrc
echo 'export PATH="$PATH:/usr/bin/Postman"' >> ~/.tempzshrc
source ~/.tempzshrc
sudo -u $SUDO_USER echo '# Postman path' >> ~/.tempzshrc
sudo -u $SUDO_USER echo 'export PATH="$PATH:/usr/bin/Postman"' >> ~/.tempzshrc
fi
# always put in bashrc aswell, so that the user can always rely on the standard shell
echo '# Postman path' >> ~/.bashrc
echo 'export PATH="$PATH:/usr/bin/Postman"' >> ~/.bashrc
sudo -u $SUDO_USER echo '# Postman path' >> ~/.bashrc
sudo -u $SUDO_USER echo 'export PATH="$PATH:/usr/bin/Postman"' >> ~/.bashrc
source ~/.bashrc
# Create file and set info