commit c433d47759b99d7b9844020279fe5f12e8ebe5b9
parent f4abc94afbe4b37e2643a4336c31ec5683c9a1a8
Author: Friedel Schön <[email protected]>
Date: Fri, 9 Aug 2024 01:34:12 +0200
theming and formatting
Diffstat:
12 files changed, 69 insertions(+), 48 deletions(-)
diff --git a/configs/dwm.h b/configs/dwm.h
@@ -23,12 +23,10 @@ static const int systraypinningfailfirst =
static const int showsystray = 1; /* 0 means no systray */
static const char *fonts[] = {"Source Code Pro:size=9"};
static const char *colors[][3] = { // dark
-
-// #104b51, #3b484d, #674448, #924144 and #bd3d3f.
/* fg bg border */
- [SchemeNorm] = {white, "#3b484d", "#3b484d"},
- [SchemeSel] = {black, "#bd3d3f", "#bd3d3f"},
- [SchemeUrg] = {orange, gray3, orange},
+ [SchemeNorm] = {gray2, white, gray2},
+ [SchemeSel] = {gray2, blue, blue},
+ [SchemeUrg] = {white, orange, orange},
[3] = {gray3, orange, gray2},
[4] = {gray3, green, gray2}
};
diff --git a/configs/slstatus.h b/configs/slstatus.h
@@ -73,10 +73,10 @@ static const struct arg args[] = {
{ netspeed_rx, always, " %8sB/s", "wlp2s0" },
{ netspeed_tx, always, " | %8sB/s", "wlp2s0" },
{ cat, always, " | %s", "/tmp/xbps-updates.txt" },
- { ram_perc, always, " | %3s%%", NULL },
+ // { ram_perc, always, " | %3s%%", NULL },
{ cpu_perc, always, " | %3s%%", NULL },
- { battery_state,always," | %s ", "BAT0" },
- { battery_perc,always, "%s%%", "BAT0" },
- { battery_remaining, battery_discharge, " (%s)", "BAT0" },
+ // { battery_state,always," | %s ", "BAT0" },
+ // { battery_perc,always, "%s%%", "BAT0" },
+ // { battery_remaining, battery_discharge, " (%s)", "BAT0" },
{ datetime, always, " | %s", "%d-%m-%y %H:%M:%S" },
};
diff --git a/configs/st.h b/configs/st.h
@@ -5,7 +5,7 @@
*
* font: see http://freedesktop.org/software/fontconfig/fontconfig-user.html
*/
-static char font[] = "Monaco:size=9";
+static char font[] = "Fira Code:size=9";
static int borderpx = 5;
/*
diff --git a/home.nix b/home.nix
@@ -19,6 +19,7 @@ rec {
(pkgs.callPackage pkgs/stw.nix { })
(pkgs.callPackage pkgs/tabbed.nix { })
(pkgs.callPackage pkgs/surf.nix { })
+ (pkgs.callPackage pkgs/textselect.nix { })
# use nix' nix, it is more up-to-date
pkgs.nix
diff --git a/pkgs/st.nix b/pkgs/st.nix
@@ -1,7 +1,6 @@
{ pkgs
, fetchurl
, mkSucklessPackage ? pkgs.callPackage ../common/suckless-pkg.nix { }
-,
}:
mkSucklessPackage rec {
diff --git a/pkgs/surf.nix b/pkgs/surf.nix
@@ -1,4 +1,7 @@
-{ pkgs, fetchurl, mkSucklessPackage ? pkgs.callPackage ../common/suckless-pkg.nix { } }:
+{ pkgs
+, fetchurl
+, mkSucklessPackage ? pkgs.callPackage ../common/suckless-pkg.nix { }
+}:
mkSucklessPackage {
name = "surf";
diff --git a/pkgs/tabbed.nix b/pkgs/tabbed.nix
@@ -1,4 +1,7 @@
-{ pkgs, fetchurl, mkSucklessPackage ? pkgs.callPackage ../common/suckless-pkg.nix { } }:
+{ pkgs
+, fetchurl
+, mkSucklessPackage ? pkgs.callPackage ../common/suckless-pkg.nix { }
+}:
mkSucklessPackage {
name = "tabbed";
diff --git a/pkgs/textselect.nix b/pkgs/textselect.nix
@@ -0,0 +1,22 @@
+{ pkgs
+, stdenv
+}:
+
+stdenv.mkDerivation rec {
+ name = "weakbox";
+ src = fetchGit {
+ url = "https://github.com/friedelschoen/textselect";
+ rev = "6131d1ae07f5af71f2df14a5f82a9e64b7ea5ebe";
+ };
+
+ buildInputs = with pkgs; [ ncurses ];
+
+ buildPhase = ''
+ make all
+ '';
+
+ installPhase = ''
+ mkdir -p $out/bin/ $out/share/man/man1/
+ make PREFIX=$out install
+ '';
+}
diff --git a/pkgs/void-runit.nix b/pkgs/void-runit.nix
@@ -1,6 +1,9 @@
-{ pkgs ? import <nixpkgs> { } }:
+{ pkgs
+, stdenv
+, fetchzip
+}:
-with pkgs; stdenv.mkDerivation rec {
+stdenv.mkDerivation rec {
name = "runit-utils";
version = "20231124";
diff --git a/pkgs/weakbox.nix b/pkgs/weakbox.nix
@@ -1,14 +1,14 @@
-{ pkgs ? import <nixpkgs> { }, config ? { } }:
+{ pkgs
+, stdenv
+}:
-with pkgs; stdenv.mkDerivation rec {
+stdenv.mkDerivation rec {
name = "weakbox";
src = fetchGit {
url = "https://git.friedelschoen.io/weakbox";
rev = "8f7e0468e1fc92e57c8a77f1a49a67846fcce114";
};
- buildInputs = [ ];
-
buildPhase = ''
make all
'';
diff --git a/services.nix b/services.nix
@@ -66,6 +66,16 @@ with pkgs; [
'';
}
{
+ name = "cbatticon";
+ enable = true;
+ setup = "";
+ run = writeScript "cbatticon-run" ''
+ #!/bin/sh
+
+ exec cbatticon
+ '';
+ }
+ {
name = "slstatus";
enable = true;
setup = "";
diff --git a/theme.nix b/theme.nix
@@ -1,37 +1,19 @@
{ lib }:
let
-
- # Black | rgb(40, 44, 52) | #282c34 |
- # " | White | rgb(171, 178, 191) | #abb2bf |
- # " | Light Red | rgb(224, 108, 117) | #e06c75 |
- # " | Dark Red | rgb(190, 80, 70) | #be5046 |
- # " | Green | rgb(152, 195, 121) | #98c379 |
- # " | Light Yellow | rgb(229, 192, 123) | #e5c07b |
- # " | Dark Yellow | rgb(209, 154, 102) | #d19a66 |
- # " | Blue | rgb(97, 175, 239) | #61afef |
- # " | Magenta | rgb(198, 120, 221) | #c678dd |
- # " | Cyan | rgb(86, 182, 194) | #56b6c2 |
- # " | Gutter Grey | rgb(76, 82, 99) | #4b5263 |
- # " | Comment Grey | rgb(92, 99, 112) | #5c6370 |
-
colors = {
- black = "#282c34";
- blue = "#61afef";
- gray2 = "#4b5263";
- gray3 = "#5c6370";
- gray4 = "#4b5263";
- green = "#98c379";
- orange = "#d19a66";
- pink = "#e06c75";
- red = "#be5046";
- white = "#abb2bf";
- yellow = "#e5c07b";
- magenta = "#c678dd";
- cyan = "#56b6c2";
+ black = "#282828";
+ blue = "#83a598";
+ gray2 = "#282828";
+ gray3 = "#3c3836";
+ gray4 = "#282828";
+ green = "#8ec07c";
+ orange = "#fe8019";
+ pink = "#d3869b";
+ red = "#fb4934";
+ white = "#ebdbb2";
+ yellow = "#b8bb26";
};
- #251d3a, #2a2550, #e04d01 and #ff7700.
-
header = lib.concatStrings (lib.mapAttrsToList (name: value: "static const char ${name}[] = \"${value}\";\n") colors);
in
builtins.toFile "theme.h" header