about summary refs log tree commit diff stats
path: root/sys/nixpkgs/pkgs/scripts/source
diff options
context:
space:
mode:
authorSoispha <soispha@vhack.eu>2024-03-01 21:17:50 +0100
committerSoispha <soispha@vhack.eu>2024-03-01 21:17:50 +0100
commita9ff740abec02395fcf23db3f704d8ecce4d0bed (patch)
tree1d0c1f75669aefba9710dcef45b0b4db4406c8ab /sys/nixpkgs/pkgs/scripts/source
parentchore(version): v1.36.2 (diff)
downloadnixos-config-a9ff740abec02395fcf23db3f704d8ecce4d0bed.tar.gz
nixos-config-a9ff740abec02395fcf23db3f704d8ecce4d0bed.zip
feat(pkgs/neorg/review): Init
This makes reviewing (and closing) opened firefox tabs easier.
Diffstat (limited to '')
-rwxr-xr-xsys/nixpkgs/pkgs/scripts/source/specific/neorg/sh/functions/review.sh9
-rwxr-xr-xsys/nixpkgs/pkgs/scripts/source/specific/neorg/sh/main.sh9
2 files changed, 18 insertions, 0 deletions
diff --git a/sys/nixpkgs/pkgs/scripts/source/specific/neorg/sh/functions/review.sh b/sys/nixpkgs/pkgs/scripts/source/specific/neorg/sh/functions/review.sh
new file mode 100755
index 00000000..ab9ec6b1
--- /dev/null
+++ b/sys/nixpkgs/pkgs/scripts/source/specific/neorg/sh/functions/review.sh
@@ -0,0 +1,9 @@
+#!/usr/bin/env dash
+
+review0start() {
+    for project in $(list0list_all_contexts_newline); do
+        msg "Starting '$project'"
+        notify-send "Neorg" "Starting '$project'"
+        firefox -P "$project"
+    done
+}
diff --git a/sys/nixpkgs/pkgs/scripts/source/specific/neorg/sh/main.sh b/sys/nixpkgs/pkgs/scripts/source/specific/neorg/sh/main.sh
index 249856a9..bf07bbd6 100755
--- a/sys/nixpkgs/pkgs/scripts/source/specific/neorg/sh/main.sh
+++ b/sys/nixpkgs/pkgs/scripts/source/specific/neorg/sh/main.sh
@@ -13,6 +13,7 @@ SHELL_LIBRARY_VERSION="2.1.1" . %SHELL_LIBRARY_PATH
 . ./functions/project.sh
 . ./functions/utils.sh
 . ./functions/workspace.sh
+. ./functions/review.sh
 
 # these are used in version()
 # shellcheck disable=2034
@@ -66,6 +67,9 @@ COMMANDS:
 
     fstop
                             Stops the current active task
+
+    review
+                            Review all firefox tabs
 ARGUMENTS:
     ID | *([0-9]) := [[%ID_GENERATION_FUNCTION]]
                             The function displays all possible IDs of the eligable tasks.
@@ -144,6 +148,11 @@ while [ "$#" -ne 0 ]; do
         fstop0stop_current_task
         exit 0
         ;;
+    "r"*) # review
+        shift 1
+        review0start
+        exit 0
+        ;;
     *)
         die "Command '$1' does not exist! Please look at:\n $NAME --help"
         exit 0