]> Skullheadx's Git Forge - dmenu.git/commitdiff
flake + config
authorSkullheadx <admonty1@protonmail.com>
Wed, 29 Apr 2026 22:39:51 +0000 (18:39 -0400)
committerSkullheadx <admonty1@protonmail.com>
Wed, 29 Apr 2026 22:39:51 +0000 (18:39 -0400)
.gitignore [new file with mode: 0644]
config.def.h
config.h [new file with mode: 0644]
flake.lock [new file with mode: 0644]
flake.nix [new file with mode: 0644]

diff --git a/.gitignore b/.gitignore
new file mode 100644 (file)
index 0000000..c4a847d
--- /dev/null
@@ -0,0 +1 @@
+/result
index 1edb647789c7befe9e98a046a78260e4b580a30a..97be685b7443a7b3ce3b4f697d9e6fd7e5a4e4de 100644 (file)
@@ -4,7 +4,7 @@
 static int topbar = 1;                      /* -b  option; if 0, dmenu appears at bottom     */
 /* -fn option overrides fonts[0]; default X11 font or font set */
 static const char *fonts[] = {
-       "monospace:size=10"
+       "monospace:size=16"
 };
 static const char *prompt      = NULL;      /* -p  option; prompt to the left of input field */
 static const char *colors[SchemeLast][2] = {
diff --git a/config.h b/config.h
new file mode 100644 (file)
index 0000000..97be685
--- /dev/null
+++ b/config.h
@@ -0,0 +1,23 @@
+/* See LICENSE file for copyright and license details. */
+/* Default settings; can be overriden by command line. */
+
+static int topbar = 1;                      /* -b  option; if 0, dmenu appears at bottom     */
+/* -fn option overrides fonts[0]; default X11 font or font set */
+static const char *fonts[] = {
+       "monospace:size=16"
+};
+static const char *prompt      = NULL;      /* -p  option; prompt to the left of input field */
+static const char *colors[SchemeLast][2] = {
+       /*     fg         bg       */
+       [SchemeNorm] = { "#bbbbbb", "#222222" },
+       [SchemeSel] = { "#eeeeee", "#005577" },
+       [SchemeOut] = { "#000000", "#00ffff" },
+};
+/* -l option; if nonzero, dmenu uses vertical list with given number of lines */
+static unsigned int lines      = 0;
+
+/*
+ * Characters not considered part of a word while deleting words
+ * for example: " /?\"&[]"
+ */
+static const char worddelimiters[] = " ";
diff --git a/flake.lock b/flake.lock
new file mode 100644 (file)
index 0000000..bbfee60
--- /dev/null
@@ -0,0 +1,27 @@
+{
+  "nodes": {
+    "nixpkgs": {
+      "locked": {
+        "lastModified": 1777268161,
+        "narHash": "sha256-bxrdOn8SCOv8tN4JbTF/TXq7kjo9ag4M+C8yzzIRYbE=",
+        "owner": "nixos",
+        "repo": "nixpkgs",
+        "rev": "1c3fe55ad329cbcb28471bb30f05c9827f724c76",
+        "type": "github"
+      },
+      "original": {
+        "owner": "nixos",
+        "ref": "nixos-unstable",
+        "repo": "nixpkgs",
+        "type": "github"
+      }
+    },
+    "root": {
+      "inputs": {
+        "nixpkgs": "nixpkgs"
+      }
+    }
+  },
+  "root": "root",
+  "version": 7
+}
diff --git a/flake.nix b/flake.nix
new file mode 100644 (file)
index 0000000..99a631b
--- /dev/null
+++ b/flake.nix
@@ -0,0 +1,35 @@
+{
+  description = "flake for building dmenu";
+
+  inputs = {
+    nixpkgs.url = "github:nixos/nixpkgs?ref=nixos-unstable";
+  };
+
+  outputs =
+    { self, nixpkgs }:
+    let
+      system = "x86_64-linux";
+      pkgs = import nixpkgs { inherit system; };
+
+    in
+    {
+      packages.${system}.default = pkgs.stdenv.mkDerivation {
+        pname = "dmenu";
+        version = "5.4";
+        src = ./.;
+
+        nativeBuildInputs = [ pkgs.pkg-config ];
+        buildInputs = with pkgs; [
+          libX11
+          fontconfig
+          libxinerama
+          libxft
+        ];
+        makeFlags = [
+          "PREFIX=$(out)"
+          "CC:=$(CC)"
+        ];
+
+      };
+    };
+}