]> Skullheadx's Git Forge - nixos.git/commitdiff
scripts dir
authorSkullheadx <admonty1@protonmail.com>
Wed, 29 Apr 2026 21:33:13 +0000 (17:33 -0400)
committerSkullheadx <admonty1@protonmail.com>
Wed, 29 Apr 2026 21:33:13 +0000 (17:33 -0400)
configuration.nix
flake.lock
flake.nix
overlays.nix
scripts/lock-screen.nix [moved from lock-screen.nix with 100% similarity]
scripts/scrolling-title.nix [new file with mode: 0644]
x11.nix

index cf9c76e7c42ac8210eff8d0fbcebe53e6bae02d2..ea3ac6e428b8d2a224ab8da0ba4ab903ab026131 100644 (file)
@@ -50,6 +50,7 @@
         exec ${pkgs.nvi}/bin/vi "$@"
       '';
     })
+
     neovim
     wget
     git
     xdotool
     gcc
     slstatus
+    scrolling-title
     surf
     terminus_font
     terminus_font_ttf
+
   ];
 
   programs.git = {
index 0c75e078872368b7f8b1c607607597de3300936b..ee28f4bf11a8be37fc0b6e8492d597d65664a659 100644 (file)
         ]
       },
       "locked": {
-        "lastModified": 1777454369,
-        "narHash": "sha256-inaQz2ijnGAGCYCVUN8u09KkNujPSRdU2+ikcL4gW5Q=",
+        "lastModified": 1777494424,
+        "narHash": "sha256-2cLtUE+vHQcAf8C9T6UGl1VLNFsHqxlBLcv/q6kXJCk=",
         "owner": "Skullheadx",
         "repo": "dwm",
-        "rev": "230d4c1552be9378e16cd1b14daff57ad1e00b19",
+        "rev": "07b18fb47183244401c4389e469d6a249ac282ab",
         "type": "github"
       },
       "original": {
         ]
       },
       "locked": {
-        "lastModified": 1777453951,
-        "narHash": "sha256-ZMtKdkzIFFkruKhbkIi+6snBIyhsUETYqIA3LoQFXwQ=",
+        "lastModified": 1777498357,
+        "narHash": "sha256-Ij9dCS37935ieuSk67KtU+7pp9YVr6M3s5IhVkRd1Q0=",
         "owner": "Skullheadx",
         "repo": "slstatus",
-        "rev": "88af0b1eab66ff753004e55b549764f9cfa1af6c",
+        "rev": "efd7e7de9197b0136b0f9a011e6a78d792991168",
         "type": "github"
       },
       "original": {
index dc838ff4b49b7cecf440f0bf47c222424e148cdf..81cdfa69975cc4fdcd46ba139d5fa319f37ab13c 100644 (file)
--- a/flake.nix
+++ b/flake.nix
       url = "github:Skullheadx/surf";
       inputs.nixpkgs.follows = "nixpkgs";
     };
-    
+
     my-dwm = {
       url = "github:Skullheadx/dwm";
       inputs.nixpkgs.follows = "nixpkgs";
     };
 
-    my-st  = {
+    my-st = {
       url = "github:Skullheadx/st";
       inputs.nixpkgs.follows = "nixpkgs";
     };
index a5b6c3a10d98c1e1d79958480d417fee38ba405b..0cd01f1831cf3e4406fc7ff630a24f4e1d16eb54 100644 (file)
@@ -2,7 +2,10 @@
 {
   nixpkgs.overlays = [
     (final: prev: {
-      lock-screen = import ./lock-screen.nix { pkgs = prev; };
+      lock-screen = import ./scripts/lock-screen.nix { pkgs = prev; };
+    })
+    (final: prev: {
+      scrolling-title = import ./scripts/scrolling-title.nix { pkgs = prev; };
     })
     (final: prev: {
       slstatus = inputs.my-slstatus.packages.${pkgs.stdenv.hostPlatform.system}.default;
similarity index 100%
rename from lock-screen.nix
rename to scripts/lock-screen.nix
diff --git a/scripts/scrolling-title.nix b/scripts/scrolling-title.nix
new file mode 100644 (file)
index 0000000..0bafa1b
--- /dev/null
@@ -0,0 +1,24 @@
+{ pkgs }:
+pkgs.writeShellApplication {
+  name = "scrolling-title";
+  runtimeInputs = with pkgs; [ mpc coreutils ];
+  text = ''
+    WIDTH=16
+    PADDING="          "
+    
+    RAW_STR=$(mpc current)
+    
+    if [ -z "$RAW_STR" ]; then
+      echo "Stopped"
+      exit 0
+    fi
+
+    STR="$RAW_STR$PADDING"
+    LEN=''${#STR} 
+
+    T=$(date +%s)
+    INDEX=$(( T % LEN ))
+
+    # Output the scrolled window
+    echo "$STR$STR" | cut -c "$((INDEX + 1))-$((INDEX + WIDTH))"'';
+}
diff --git a/x11.nix b/x11.nix
index cd2d10db3739589c2f8da0b4d7dbd53cd434c41a..2648bf8b037a0c24ba8ef80e6ee0942b7e8b7f27 100644 (file)
--- a/x11.nix
+++ b/x11.nix
@@ -49,7 +49,6 @@
     '';
   };
 
-
   services.picom = {
     enable = true;
   };