add battery tmux plugin to yuzu
This commit is contained in:
parent
81c7356b24
commit
6fa90af645
|
|
@ -1,7 +1,20 @@
|
||||||
{config, ...}: {
|
{
|
||||||
|
config,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
imports = [
|
imports = [
|
||||||
../../../../user
|
../../../../user
|
||||||
];
|
];
|
||||||
|
|
||||||
home.username = "ahnwuoa";
|
home.username = "ahnwuoa";
|
||||||
|
home.packages = [pkgs.acpi];
|
||||||
|
u.tmux = {
|
||||||
|
plugins = [pkgs.tmuxPlugins.battery];
|
||||||
|
extraConfig = ''
|
||||||
|
set -g status-right "#{client_user}@#H | #{battery_percentage} #{battery_remain} | %a %b %d, %H:%M"
|
||||||
|
set -g status-right-length 60
|
||||||
|
set -g status-interval 15
|
||||||
|
'';
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,11 +1,21 @@
|
||||||
{
|
{
|
||||||
config,
|
config,
|
||||||
pkgs,
|
pkgs,
|
||||||
|
lib,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
mkln = x: config.lib.file.mkOutOfStoreSymlink "${config.home.homeDirectory}/.local/nixos/user/config/${x}";
|
mkln = x: config.lib.file.mkOutOfStoreSymlink "${config.home.homeDirectory}/.local/nixos/user/config/${x}";
|
||||||
|
tmuxConfig = config.u.tmux.extraConfig + lib.strings.concatMapStrings (x: "\nrun ${x.rtp}") config.u.tmux.plugins;
|
||||||
in {
|
in {
|
||||||
imports = [./kde];
|
imports = [./kde];
|
||||||
|
|
||||||
|
u.tmux.plugins = with pkgs.tmuxPlugins; [
|
||||||
|
vim-tmux-navigator
|
||||||
|
sessionist
|
||||||
|
];
|
||||||
|
fonts.fontconfig.enable = false;
|
||||||
|
gtk.gtk2.configLocation = "${config.xdg.configHome}/gtk-2.0/gtkrc";
|
||||||
|
|
||||||
xdg.configFile.alacritty.source = mkln "alacritty";
|
xdg.configFile.alacritty.source = mkln "alacritty";
|
||||||
xdg.configFile.awesome.source = mkln "awesome";
|
xdg.configFile.awesome.source = mkln "awesome";
|
||||||
xdg.configFile.bash.source = mkln "bash";
|
xdg.configFile.bash.source = mkln "bash";
|
||||||
|
|
@ -25,12 +35,5 @@ in {
|
||||||
xdg.configFile.readline.source = ./readline;
|
xdg.configFile.readline.source = ./readline;
|
||||||
xdg.configFile."starship.toml".source = ./starship.toml;
|
xdg.configFile."starship.toml".source = ./starship.toml;
|
||||||
xdg.configFile.sx.source = mkln "sx";
|
xdg.configFile.sx.source = mkln "sx";
|
||||||
xdg.configFile."tmux/tmux.conf".text =
|
xdg.configFile."tmux/tmux.conf".text = (builtins.readFile tmux/tmux.conf) + tmuxConfig;
|
||||||
(builtins.readFile tmux/tmux.conf)
|
|
||||||
+ ''
|
|
||||||
run ${pkgs.tmuxPlugins.vim-tmux-navigator.rtp}
|
|
||||||
run ${pkgs.tmuxPlugins.sessionist.rtp}
|
|
||||||
'';
|
|
||||||
fonts.fontconfig.enable = false;
|
|
||||||
gtk.gtk2.configLocation = "${config.xdg.configHome}/gtk-2.0/gtkrc";
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,7 @@
|
||||||
./bin
|
./bin
|
||||||
./config
|
./config
|
||||||
./home.nix
|
./home.nix
|
||||||
|
./options.nix
|
||||||
./share
|
./share
|
||||||
./theme.nix
|
./theme.nix
|
||||||
./xdg.nix
|
./xdg.nix
|
||||||
|
|
|
||||||
15
user/options.nix
Normal file
15
user/options.nix
Normal file
|
|
@ -0,0 +1,15 @@
|
||||||
|
{lib, ...}: {
|
||||||
|
options.u = {
|
||||||
|
tmux = {
|
||||||
|
plugins = lib.mkOption {
|
||||||
|
type = lib.types.listOf lib.types.package;
|
||||||
|
description = "tmux plugins to source in config";
|
||||||
|
};
|
||||||
|
extraConfig = lib.mkOption {
|
||||||
|
type = lib.types.lines;
|
||||||
|
description = "extra config to append to bottom of config";
|
||||||
|
default = "";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
Loading…
Reference in a new issue