summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorAndrew Opalach <andrew@akon.city> 2025-05-28 14:24:58 -0400
committerAndrew Opalach <andrew@akon.city> 2025-05-28 14:24:58 -0400
commita28487fe6fbac72c7b1a752acab42dcc6ab46476 (patch)
treec3b1b9b751dd5e96b4afc835decf14ce38fd35f8 /scripts
parent75ad6c3fcad1f19c4f4f5c345fbb43ce80d9c461 (diff)
downloaddotfiles-a28487fe6fbac72c7b1a752acab42dcc6ab46476.tar.gz
dotfiles-a28487fe6fbac72c7b1a752acab42dcc6ab46476.tar.bz2
dotfiles-a28487fe6fbac72c7b1a752acab42dcc6ab46476.zip
Post server fs corruption
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/desktop/7z-password2
-rwxr-xr-xscripts/desktop/battery (renamed from scripts/battery)0
-rwxr-xr-xscripts/desktop/cpu-vulns (renamed from scripts/cpu-vulns)0
-rwxr-xr-xscripts/desktop/dbus-sway-environment (renamed from scripts/dbus-sway-environment)0
-rwxr-xr-xscripts/desktop/discord-wayland (renamed from scripts/discord-wayland)0
-rwxr-xr-xscripts/desktop/dmenu-emoji (renamed from scripts/dmenu-emoji)0
-rwxr-xr-xscripts/desktop/dmenu-path (renamed from scripts/dmenu-path)0
-rwxr-xr-xscripts/desktop/dmenu-path0 (renamed from scripts/dmenu-path0)0
-rwxr-xr-xscripts/desktop/gpg-pubkey (renamed from scripts/gpg-pubkey)0
-rwxr-xr-xscripts/desktop/img-fstype (renamed from scripts/img-fstype)0
-rwxr-xr-xscripts/desktop/install-as-needed (renamed from scripts/install-as-needed)0
-rwxr-xr-xscripts/desktop/looking-glass (renamed from scripts/looking-glass)0
-rwxr-xr-xscripts/desktop/moonrune-charset-utf8 (renamed from scripts/moonrune-charset-utf8)0
-rwxr-xr-xscripts/desktop/mount-nfs (renamed from scripts/mount-nfs)0
-rwxr-xr-xscripts/desktop/rewrite-git (renamed from scripts/rewrite-git)0
-rwxr-xr-xscripts/desktop/screenshot (renamed from scripts/screenshot)0
-rwxr-xr-xscripts/desktop/shift-jis-zip (renamed from scripts/shift-jis-zip)0
-rwxr-xr-xscripts/desktop/sp (renamed from scripts/sp)0
-rwxr-xr-xscripts/desktop/term-font-size (renamed from scripts/term-font-size)0
-rwxr-xr-xscripts/desktop/ts-date (renamed from scripts/ts-date)0
-rwxr-xr-xscripts/desktop/wlsunset-toggle (renamed from scripts/wlsunset-toggle)0
-rwxr-xr-xscripts/desktop/xbox360-ffmpeg-enc (renamed from scripts/xbox360-ffmpeg-enc)0
-rwxr-xr-xscripts/sync/diff.sh8
-rwxr-xr-xscripts/sync/pull.sh34
-rwxr-xr-xscripts/sync/push.sh34
25 files changed, 78 insertions, 0 deletions
diff --git a/scripts/desktop/7z-password b/scripts/desktop/7z-password
new file mode 100755
index 0000000..72e90f9
--- /dev/null
+++ b/scripts/desktop/7z-password
@@ -0,0 +1,2 @@
+#! /usr/bin/env sh
+7z a -p -mhe=on $1 $2
diff --git a/scripts/battery b/scripts/desktop/battery
index c09992a..c09992a 100755
--- a/scripts/battery
+++ b/scripts/desktop/battery
diff --git a/scripts/cpu-vulns b/scripts/desktop/cpu-vulns
index e55ad9c..e55ad9c 100755
--- a/scripts/cpu-vulns
+++ b/scripts/desktop/cpu-vulns
diff --git a/scripts/dbus-sway-environment b/scripts/desktop/dbus-sway-environment
index 249d610..249d610 100755
--- a/scripts/dbus-sway-environment
+++ b/scripts/desktop/dbus-sway-environment
diff --git a/scripts/discord-wayland b/scripts/desktop/discord-wayland
index ec8a106..ec8a106 100755
--- a/scripts/discord-wayland
+++ b/scripts/desktop/discord-wayland
diff --git a/scripts/dmenu-emoji b/scripts/desktop/dmenu-emoji
index 07c1900..07c1900 100755
--- a/scripts/dmenu-emoji
+++ b/scripts/desktop/dmenu-emoji
diff --git a/scripts/dmenu-path b/scripts/desktop/dmenu-path
index 9c8122a..9c8122a 100755
--- a/scripts/dmenu-path
+++ b/scripts/desktop/dmenu-path
diff --git a/scripts/dmenu-path0 b/scripts/desktop/dmenu-path0
index 593ecf6..593ecf6 100755
--- a/scripts/dmenu-path0
+++ b/scripts/desktop/dmenu-path0
diff --git a/scripts/gpg-pubkey b/scripts/desktop/gpg-pubkey
index 5353972..5353972 100755
--- a/scripts/gpg-pubkey
+++ b/scripts/desktop/gpg-pubkey
diff --git a/scripts/img-fstype b/scripts/desktop/img-fstype
index 82df6b8..82df6b8 100755
--- a/scripts/img-fstype
+++ b/scripts/desktop/img-fstype
diff --git a/scripts/install-as-needed b/scripts/desktop/install-as-needed
index 9db4ff1..9db4ff1 100755
--- a/scripts/install-as-needed
+++ b/scripts/desktop/install-as-needed
diff --git a/scripts/looking-glass b/scripts/desktop/looking-glass
index 5ce9cf4..5ce9cf4 100755
--- a/scripts/looking-glass
+++ b/scripts/desktop/looking-glass
diff --git a/scripts/moonrune-charset-utf8 b/scripts/desktop/moonrune-charset-utf8
index d3e8343..d3e8343 100755
--- a/scripts/moonrune-charset-utf8
+++ b/scripts/desktop/moonrune-charset-utf8
diff --git a/scripts/mount-nfs b/scripts/desktop/mount-nfs
index a07f4cf..a07f4cf 100755
--- a/scripts/mount-nfs
+++ b/scripts/desktop/mount-nfs
diff --git a/scripts/rewrite-git b/scripts/desktop/rewrite-git
index b48ba4d..b48ba4d 100755
--- a/scripts/rewrite-git
+++ b/scripts/desktop/rewrite-git
diff --git a/scripts/screenshot b/scripts/desktop/screenshot
index ddeb73a..ddeb73a 100755
--- a/scripts/screenshot
+++ b/scripts/desktop/screenshot
diff --git a/scripts/shift-jis-zip b/scripts/desktop/shift-jis-zip
index 30dab2e..30dab2e 100755
--- a/scripts/shift-jis-zip
+++ b/scripts/desktop/shift-jis-zip
diff --git a/scripts/sp b/scripts/desktop/sp
index 19d38a1..19d38a1 100755
--- a/scripts/sp
+++ b/scripts/desktop/sp
diff --git a/scripts/term-font-size b/scripts/desktop/term-font-size
index 0637b12..0637b12 100755
--- a/scripts/term-font-size
+++ b/scripts/desktop/term-font-size
diff --git a/scripts/ts-date b/scripts/desktop/ts-date
index f16517f..f16517f 100755
--- a/scripts/ts-date
+++ b/scripts/desktop/ts-date
diff --git a/scripts/wlsunset-toggle b/scripts/desktop/wlsunset-toggle
index 7dcd06e..7dcd06e 100755
--- a/scripts/wlsunset-toggle
+++ b/scripts/desktop/wlsunset-toggle
diff --git a/scripts/xbox360-ffmpeg-enc b/scripts/desktop/xbox360-ffmpeg-enc
index aab754f..aab754f 100755
--- a/scripts/xbox360-ffmpeg-enc
+++ b/scripts/desktop/xbox360-ffmpeg-enc
diff --git a/scripts/sync/diff.sh b/scripts/sync/diff.sh
new file mode 100755
index 0000000..61ff628
--- /dev/null
+++ b/scripts/sync/diff.sh
@@ -0,0 +1,8 @@
+#! /usr/bin/env sh
+set -e
+REMOTE="$(cat remote)"
+if [ ! -d $REMOTE ]; then
+ echo "Path $REMOTE does not exist."
+ exit 1
+fi
+diff --brief --recursive --new-file --no-dereference . $REMOTE
diff --git a/scripts/sync/pull.sh b/scripts/sync/pull.sh
new file mode 100755
index 0000000..1bf5b48
--- /dev/null
+++ b/scripts/sync/pull.sh
@@ -0,0 +1,34 @@
+#! /usr/bin/env sh
+
+set -e
+
+SOURCE="$(cat remote)/"
+if [ ! -d $SOURCE ]; then
+ echo "Path $SOURCE does not exist."
+ exit 1
+fi
+
+ARGS=()
+FORCE=0
+while getopts 'cfdr' opt; do
+ case "$opt" in
+ c) # Changes
+ ARGS+=('--delete')
+ ;;
+ f) # Full
+ ARGS+=('--checksum')
+ ;;
+ d) # Dry
+ ARGS+=('--dry-run')
+ ;;
+ r) # Revert
+ FORCE=1
+ ;;
+ esac
+done
+
+if [ $FORCE = 0 ]; then
+ ARGS+=('--update')
+fi
+
+rsync --archive --itemize-changes "${ARGS[@]}" $SOURCE .
diff --git a/scripts/sync/push.sh b/scripts/sync/push.sh
new file mode 100755
index 0000000..3adbd02
--- /dev/null
+++ b/scripts/sync/push.sh
@@ -0,0 +1,34 @@
+#! /usr/bin/env sh
+
+set -e
+
+DEST="$(cat remote)"
+if [ ! -d $DEST ]; then
+ echo "Path $DEST does not exist."
+ exit 1
+fi
+
+ARGS=()
+FORCE=0
+while getopts 'cfdr' opt; do
+ case "$opt" in
+ c) # Changes
+ ARGS+=('--delete')
+ ;;
+ f) # Full
+ ARGS+=('--checksum')
+ ;;
+ d) # Dry
+ ARGS+=('--dry-run')
+ ;;
+ r) # Revert
+ FORCE=1
+ ;;
+ esac
+done
+
+if [ $FORCE = 0 ]; then
+ ARGS+=('--update')
+fi
+
+rsync --archive --itemize-changes "${ARGS[@]}" ./ $DEST