Skip to content
Snippets Groups Projects
Commit 22a1c8fb authored by Marko Gobin's avatar Marko Gobin
Browse files

Revert "fixed wrong description in readme.md"

This reverts commit 8768faca
parent 44172c8c
Branches master
No related tags found
No related merge requests found
\.directory
aur/
......@@ -8,7 +8,7 @@ Timeshift auto-snapshot script which runs before package upgrade using Pacman ho
* Can be manually executed by running `timeshift-autosnap` command with elevated privileges.
# /etc/timeshift-autosnap.conf options:
* `skipAutosnap` - if set to **false** script won't be executed.
* `skipAutosnap` - if set to **true** script won't be executed.
* `deleteSnapshots` - if set to **false** old snapshots won't be deleted.
* `maxSnapshots` - defines **maximum** number of old snapshots to keep.
* `updateGrub` - if set to **false** grub entries won't be generated.
......@@ -18,4 +18,4 @@ Timeshift auto-snapshot script which runs before package upgrade using Pacman ho
* This script is made in Arch and Arch based distros in mind but if there would be interest it should be easily ported to other distros.
# Contribution
* All new ideas and contributors are welcomed!
\ No newline at end of file
* All new ideas and contributors are welcomed!
#!/bin/bash
#author: gobonja
if [ $(findmnt / -no fstype) == "overlay" ] ; then
echo "==> skipping timeshift-autosnap because system is booted in Live CD mode..."; exit 0;
fi
readonly CONF_FILE=/etc/timeshift-autosnap.conf
readonly SNAPSHOTS_TO_DELETE=/tmp/timeshift-autosnap-tmp
......@@ -29,7 +33,7 @@ if $(get_property "skipAutosnap" "boolean" "false") ; then
echo "==> skipping timeshift-autosnap due skipAutosnap in $CONF_FILE set to TRUE." >&2; exit 0;
fi
timeshift --create --comments "$SNAPSHOT_DESCRIPTION" || { echo "Please close Timeshift and try again. Script will now exit..." >&2; exit 1; }
timeshift --create --comments "$SNAPSHOT_DESCRIPTION" || { echo "Unable to run timeshift-autosnap! Please close Timeshift and try again. Script will now exit..." >&2; exit 1; }
if $(get_property "deleteSnapshots" "boolean" "true") ; then
timeshift --list > $SNAPSHOTS_TO_DELETE
......@@ -51,4 +55,4 @@ if $(get_property "updateGrub" "boolean" "true") && [ "$(pacman -Qs ^grub-btrfs$
grub-mkconfig -o /boot/grub/grub.cfg
fi;
exit 0
\ No newline at end of file
exit 0
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment