ibi icon

mystart.sh

ibi | PRO | 02/02/22 09:57:48 AM UTC (Edited) | 0 ⭐ | 401 πŸ‘οΈ | Never ⏰ | []
Bash |

640 B

|

None

|

0 πŸ‘

/

0 πŸ‘Ž

#!/bin/sh
# run with @reboot in crontab
# make ramdisk subdirs
mkdir -p /mnt/ramdisk/caches/steam
mkdir -p /mnt/ramdisk/temp
# sysinf & config backup
cd ~
# last reboot > ~/logs/lastreboot.log
inxi -v4 -c0 > ~/.bck/inxi_$(hostname).txt
rar u -as -x*imapcache* -x*.iso ~/.bck/cfg_$(hostname).rar ~/.config/* ~/.mo* ~/.sylph* ~/.bashrc /etc/*tab* /etc/samba/*.conf
# unzip chromium profile
cd /mnt/ramdisk/caches/
7z x -y ~/.bck/cprfl.zip
# copy to network share
cp -fpuv ~/.bck/* /mnt/piggy/autosave/$(hostname)/lnx/ > ~/logs/cp_mystart.log
# rsync -v ~/.bck/* /mnt/piggy/autosave/$(hostname)/lnx/ | tee /mnt/piggy/logs/autosave_$(hostname).log
Β 

Comments