From 203f6dbae0fed85781af1ab7c6d067b680ab3acf Mon Sep 17 00:00:00 2001 From: Daniel Siepmann Date: Sun, 7 Jan 2024 14:37:12 +0100 Subject: [PATCH] Migrate to home manager i3blocks module This doesn't seem to work. --- home/files/i3-blocks | 36 ------------------------------------ home/packages.nix | 1 - home/programs.nix | 4 ++++ home/programs/i3blocks.nix | 14 ++++++++++++++ home/xdg.nix | 2 -- 5 files changed, 18 insertions(+), 39 deletions(-) delete mode 100644 home/files/i3-blocks create mode 100644 home/programs/i3blocks.nix diff --git a/home/files/i3-blocks b/home/files/i3-blocks deleted file mode 100644 index d1ebc39..0000000 --- a/home/files/i3-blocks +++ /dev/null @@ -1,36 +0,0 @@ -# i3blocks config file -# -# TODO: Use nix to reload the blocks on config change -# -# Please see man i3blocks for a complete reference! -# The man page is also hosted at http://vivien.github.io/i3blocks -# -# List of valid properties: -# -# align -# color -# command -# full_text -# instance -# interval -# label -# min_width -# name -# separator -# separator_block_width -# short_text -# signal -# urgent - -# Global properties -# -# The top properties below are applied to every block, but can be overridden. -# Each block command defaults to the script name to avoid boilerplate. -markup=pango - -# Date Time -[time] -command=LC_TIME=en_US.utf8 date '+📅 %a %B %Y-%m-%d %H:%M:%S'; date '+📅 %a %d. %H:%M:%S' -interval=1 - -# vi: ft=conf diff --git a/home/packages.nix b/home/packages.nix index 5d921de..f0f6f49 100644 --- a/home/packages.nix +++ b/home/packages.nix @@ -11,7 +11,6 @@ with pkgs; [ libnotify # Provide notify-send command networkmanager_dmenu - i3blocks st ncdu tree diff --git a/home/programs.nix b/home/programs.nix index 27eda1b..5f6acd6 100644 --- a/home/programs.nix +++ b/home/programs.nix @@ -17,6 +17,10 @@ in { inherit pkgs sqlformat; }; + i3blocks = import ./programs/i3blocks.nix { + inherit pkgs; + }; + git = import ./programs/git.nix { inherit pkgs; }; diff --git a/home/programs/i3blocks.nix b/home/programs/i3blocks.nix new file mode 100644 index 0000000..71d6c5b --- /dev/null +++ b/home/programs/i3blocks.nix @@ -0,0 +1,14 @@ +{ pkgs }: + +{ + enable = true; + + bars = { + top = { + time = { + interval = 1; + command = "LC_TIME=en_US.utf8 ${pkgs.coreutils}/bin/date '+📅 %a %B %Y-%m-%d %H:%M:%S'; date '+📅 %a %d. %H:%M:%S'"; + }; + }; + }; +} diff --git a/home/xdg.nix b/home/xdg.nix index 415a556..7489d6c 100644 --- a/home/xdg.nix +++ b/home/xdg.nix @@ -5,8 +5,6 @@ configFile = { - "i3blocks/config".source = ./files/i3-blocks; - "borg/exclude".source = ./files/borg-exclude; "ctags/config.ctags".source = ./files/ctags; "sc-im/scimrc".source = ./files/scimrc;