1
0
Fork 0
mirror of https://github.com/SinTan1729/random.git synced 2024-12-25 20:58:37 -06:00

Better layout

This commit is contained in:
Sayantan Santra 2022-09-17 22:09:56 -05:00
parent a00d1e7e32
commit 1ea18a0916

View file

@ -1,6 +1,7 @@
#!/bin/sh #!/bin/sh
# this is a script to backup crontab data # this is a script to backup crontab data
# put this inside /etc/cron.daily # put this inside /etc/cron.daily
# define location for output # define location for output
@ -11,4 +12,4 @@ mkdir -p $DIR
ls /etc/cron.hourly/ /etc/cron.daily/ /etc/cron.weekly/ /etc/cron.monthly/ > $DIR/crontab ls /etc/cron.hourly/ /etc/cron.daily/ /etc/cron.weekly/ /etc/cron.monthly/ > $DIR/crontab
echo "-----------------" >> $DIR/crontab echo "-----------------" >> $DIR/crontab
crontab -l >> $DIR/crontab find /var/spool/cron/ -type f -exec sh -c "echo {} && cat {} && echo ---" \; >> $DIR/crontab