summaryrefslogtreecommitdiff
path: root/.local
diff options
context:
space:
mode:
Diffstat (limited to '.local')
-rwxr-xr-x.local/bin/gitmeta3
-rwxr-xr-x.local/bin/update-agefiles12
-rwxr-xr-x.local/bin/update-gitmeta11
3 files changed, 26 insertions, 0 deletions
diff --git a/.local/bin/gitmeta b/.local/bin/gitmeta
new file mode 100755
index 0000000..b5d6081
--- /dev/null
+++ b/.local/bin/gitmeta
@@ -0,0 +1,3 @@
+#!/bin/sh
+export GIT_DIR=$HOME/.gitmeta
+exec git "$@"
diff --git a/.local/bin/update-agefiles b/.local/bin/update-agefiles
new file mode 100755
index 0000000..7b3708f
--- /dev/null
+++ b/.local/bin/update-agefiles
@@ -0,0 +1,12 @@
+#!/bin/bash
+set -e
+
+cd
+
+IFS=''
+find . -not -path '*/.*' -path '*.git' -type d |
+while read -r git_dir; do
+ pushd "$git_dir"
+ ~/git-hooks/post-receive.agefile
+ popd >/dev/null
+done
diff --git a/.local/bin/update-gitmeta b/.local/bin/update-gitmeta
new file mode 100755
index 0000000..0ace903
--- /dev/null
+++ b/.local/bin/update-gitmeta
@@ -0,0 +1,11 @@
+#!/bin/bash
+set -e
+message="$1"
+
+cd
+if [[ -n $(gitmeta status -s .) ]]; then
+ gitmeta add .
+ gitmeta commit -m "$message"
+fi
+gitmeta pull
+gitmeta push origin master