From cd25bf96e9bd318129a9001da7844845aa9101b8 Mon Sep 17 00:00:00 2001
From: Oliver Davies <oliver@oliverdavies.dev>
Date: Tue, 5 Nov 2024 07:45:36 +0000
Subject: [PATCH] Remove `notetaker` script

---
 config/awesome/rc.lua                |  5 -----
 lib/shared/home-manager-packages.nix |  2 --
 lib/shared/scripts/notetaker.nix     | 25 -------------------------
 3 files changed, 32 deletions(-)
 delete mode 100644 lib/shared/scripts/notetaker.nix

diff --git a/config/awesome/rc.lua b/config/awesome/rc.lua
index f2f72680..5565f51b 100644
--- a/config/awesome/rc.lua
+++ b/config/awesome/rc.lua
@@ -283,10 +283,6 @@ globalkeys = gears.table.join(
     awful.client.focus.byidx(1)
   end, { description = "focus next by index", group = "client" }),
 
-  awful.key({ modkey }, "n", function()
-    awful.util.spawn "alacritty --class notetaker_window --command notetaker"
-  end, { description = "open today's daily note", group = "client" }),
-
   awful.key({ modkey }, "w", function()
     mymainmenu:show()
   end, { description = "show main menu", group = "awesome" }),
@@ -594,7 +590,6 @@ awful.rules.rules = {
         "Sxiv",
         "Tor Browser", -- Needs a fixed window size to avoid fingerprinting by screen size.
         "Wpa_gui",
-        "notetaker_window",
         "veromix",
         "xtightvncviewer",
         "zoom",
diff --git a/lib/shared/home-manager-packages.nix b/lib/shared/home-manager-packages.nix
index 4754974b..fcb017a1 100644
--- a/lib/shared/home-manager-packages.nix
+++ b/lib/shared/home-manager-packages.nix
@@ -19,7 +19,6 @@ let
   export-video-list = writeShellApplication (
     import ./scripts/export-video-list.nix { inherit pkgs username; }
   );
-  notetaker = writeShellApplication (import ./scripts/notetaker.nix);
   run = writeShellApplication (import ./scripts/run.nix { inherit pkgs; });
   t = writeShellApplication (import ./scripts/t.nix { inherit pkgs; });
   timer = writeShellApplication (import ./scripts/timer.nix);
@@ -72,7 +71,6 @@ with pkgs;
   # Scripts.
   create-zellij-session
   deliver
-  notetaker
   run
   t
 ]
diff --git a/lib/shared/scripts/notetaker.nix b/lib/shared/scripts/notetaker.nix
deleted file mode 100644
index e1cc36a5..00000000
--- a/lib/shared/scripts/notetaker.nix
+++ /dev/null
@@ -1,25 +0,0 @@
-{
-  name = "notetaker";
-
-  runtimeInputs = [ ];
-
-  text = ''
-    # Based on https://github.com/CalinLeafshade/dots/blob/fe685d45201f267829b75fe5ca7e3da9d4aa4c02/bin/bin/notetaker.
-
-    today="$(date +%Y-%m-%d)"
-    note_path="''${NOTES_PATH:-$HOME/Documents/wiki}"
-    note_filename="$note_path/daily-notes/$(date +%Y)/$(date +%m)/$today.md"
-
-    if [[ ! -f "$note_filename" ]]; then
-      mkdir -p "$(dirname "$note_filename")"
-
-      echo "# $today" > "$note_filename"
-    fi
-
-    nvim -c "normal Go" \
-      -c "normal Go## $(date +%H:%M)" \
-      -c "normal G2o" \
-      -c "normal zz" \
-      -c "startinsert" "$note_filename"
-  '';
-}