26 lines
348 B
Bash
Executable File
26 lines
348 B
Bash
Executable File
#!/bin/bash
|
|
|
|
if [[ "$UID" != 0 ]]; then
|
|
echo "USER NOT ROOT"
|
|
sudo $0
|
|
exit
|
|
else
|
|
echo "USER IS ROOT"
|
|
fi
|
|
|
|
l=$(cat root.txt)
|
|
|
|
for i in $l
|
|
do
|
|
if [ -f "./root/$i" ]; then
|
|
echo "$i exist"
|
|
cp -vf /home/liveuser/$i ./root/$i
|
|
fi
|
|
done
|
|
|
|
cp -vrf /root/.config/mc/. ./root/.config/mc/.
|
|
|
|
chown -R 1000:1000 .
|
|
|
|
echo "Ready"
|