about summary refs log tree commit diff stats
path: root/pkgs/by-name/ne/neorg/functions/add.sh
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--pkgs/by-name/ne/neorg/functions/add.sh23
1 files changed, 0 insertions, 23 deletions
diff --git a/pkgs/by-name/ne/neorg/functions/add.sh b/pkgs/by-name/ne/neorg/functions/add.sh
deleted file mode 100644
index 5a830a10..00000000
--- a/pkgs/by-name/ne/neorg/functions/add.sh
+++ /dev/null
@@ -1,23 +0,0 @@
-#!/usr/bin/env dash
-
-add0open_taskwarrior_project_file() {
-    task_project_file="%TASK_PROJECT_FILE"
-
-    cd "$(dirname $task_project_file)" || die "BUG: task_project_file ('$task_project_file') can't be accessed"
-
-    git_dir="$(search_flake_base_dir)"
-    [ "$git_dir" ] || die "(BUG): No git directory?"
-    cd "$git_dir" || die "Unreachable, this MUST exists"
-
-    nvim "$task_project_file"
-    git add "$task_project_file"
-
-    base_task_project_file_path="$(awk "{ gsub(\"$git_dir/\", \"\", \$0); print }" "$(ptmp "$task_project_file")")"
-    git add $task_project_file
-
-    # Check that only the project file has been added (and that our file is actually
-    # modified)
-    if git status --porcelain=v2 | awk -v path="$base_task_project_file_path" 'BEGIN { hit = 0 } { if ($2 ~ /A./ || $2 ~ /M./) { if ($NF ~ path) { hit = 1 } else { hit = 0; exit 1 } } } END { if (hit == 1) { exit 0 } else { exit 1 } }'; then
-        git commit --verbose --message="chore($(dirname "$base_task_project_file_path")): Update"
-    fi
-}