From 20ae6cb48ef3ccb80300580b54b7dcc4c7419dc5 Mon Sep 17 00:00:00 2001 From: thomas grothe Date: Tue, 31 Oct 2023 08:38:30 -0500 Subject: added security camera scripts --- save.sh | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100755 save.sh (limited to 'save.sh') diff --git a/save.sh b/save.sh new file mode 100755 index 0000000..7419c2b --- /dev/null +++ b/save.sh @@ -0,0 +1,14 @@ +#!/bin/bash +#security camera companion script +#move recent images into a folder so they aren't deleted + +if [[ $1 ]]; then + n=${1} +else + n=40 +fi + +mv `ls -rt *png | tail -n ${n}` save/ +chmod a-w save/*png +#chmod a-w `ls -tr *png | tail -n ${n}` + -- cgit v1.2.3