Compare commits
4 Commits
88a6d046b8
...
e1a274c88e
Author | SHA1 | Date | |
---|---|---|---|
![]() |
e1a274c88e | ||
![]() |
cdc4bdffb6 | ||
![]() |
9b9a103e49 | ||
![]() |
ea7bf809fc |
@ -28,4 +28,5 @@
|
||||
me.graphical = true;
|
||||
me.graphics_card_type = "intel";
|
||||
me.kodi.enable = true;
|
||||
me.lvfs.enable = true;
|
||||
}
|
||||
|
@ -37,11 +37,14 @@
|
||||
me.docker.enable = true;
|
||||
me.emacs_flavor = "full";
|
||||
me.firefox.enable = true;
|
||||
me.git.config = ./roles/git/files/gitconfig_home;
|
||||
me.git.config = ../../roles/git/files/gitconfig_home;
|
||||
me.graphical = true;
|
||||
me.graphics_card_type = "amd";
|
||||
me.kanshi.enable = true;
|
||||
me.kubernetes.enable = true;
|
||||
me.latex.enable = true;
|
||||
me.launch_keyboard.enable = true;
|
||||
me.sway.enable = true;
|
||||
me.lvfs.enable = true;
|
||||
me.media.enable = true;
|
||||
}
|
||||
|
@ -84,7 +84,7 @@ in
|
||||
};
|
||||
};
|
||||
|
||||
environment.variables.EDITOR = "${pkgs.my_emacs}/bin/plainmacs";
|
||||
environment.variables.EDITOR = "plainmacs";
|
||||
}
|
||||
(lib.mkIf (config.me.graphical) {
|
||||
nixpkgs.overlays = [
|
||||
|
@ -32,54 +32,54 @@
|
||||
};
|
||||
};
|
||||
})
|
||||
(lib.mkIf (config.me.graphical) {
|
||||
nixpkgs.overlays = [
|
||||
(final: prev: {
|
||||
git = pkgs.buildEnv {
|
||||
name = prev.git.name;
|
||||
paths = [
|
||||
prev.git
|
||||
];
|
||||
extraOutputsToInstall = [
|
||||
"man"
|
||||
"doc"
|
||||
"info"
|
||||
];
|
||||
buildInputs = [ final.makeWrapper ];
|
||||
postBuild = ''
|
||||
wrapProgram $out/bin/git --prefix PATH : ${
|
||||
lib.makeBinPath [
|
||||
final.meld
|
||||
]
|
||||
}
|
||||
'';
|
||||
};
|
||||
})
|
||||
];
|
||||
})
|
||||
(lib.mkIf (!config.me.graphical) {
|
||||
nixpkgs.overlays = [
|
||||
(final: prev: {
|
||||
git = pkgs.buildEnv {
|
||||
name = prev.git.name;
|
||||
paths = [
|
||||
prev.git
|
||||
];
|
||||
extraOutputsToInstall = [
|
||||
"man"
|
||||
"doc"
|
||||
"info"
|
||||
];
|
||||
buildInputs = [ final.makeWrapper ];
|
||||
postBuild = ''
|
||||
wrapProgram $out/bin/git --prefix PATH : ${
|
||||
lib.makeBinPath [
|
||||
]
|
||||
}
|
||||
'';
|
||||
};
|
||||
})
|
||||
];
|
||||
})
|
||||
# (lib.mkIf (config.me.graphical) {
|
||||
# nixpkgs.overlays = [
|
||||
# (final: prev: {
|
||||
# git = pkgs.buildEnv {
|
||||
# name = prev.git.name;
|
||||
# paths = [
|
||||
# prev.git
|
||||
# ];
|
||||
# extraOutputsToInstall = [
|
||||
# "man"
|
||||
# "doc"
|
||||
# "info"
|
||||
# ];
|
||||
# buildInputs = [ final.makeWrapper ];
|
||||
# postBuild = ''
|
||||
# wrapProgram $out/bin/git --prefix PATH : ${
|
||||
# lib.makeBinPath [
|
||||
# final.meld
|
||||
# ]
|
||||
# }
|
||||
# '';
|
||||
# };
|
||||
# })
|
||||
# ];
|
||||
# })
|
||||
# (lib.mkIf (!config.me.graphical) {
|
||||
# nixpkgs.overlays = [
|
||||
# (final: prev: {
|
||||
# git = pkgs.buildEnv {
|
||||
# name = prev.git.name;
|
||||
# paths = [
|
||||
# prev.git
|
||||
# ];
|
||||
# extraOutputsToInstall = [
|
||||
# "man"
|
||||
# "doc"
|
||||
# "info"
|
||||
# ];
|
||||
# buildInputs = [ final.makeWrapper ];
|
||||
# postBuild = ''
|
||||
# wrapProgram $out/bin/git --prefix PATH : ${
|
||||
# lib.makeBinPath [
|
||||
# ]
|
||||
# }
|
||||
# '';
|
||||
# };
|
||||
# })
|
||||
# ];
|
||||
# })
|
||||
];
|
||||
}
|
||||
|
@ -8,28 +8,41 @@
|
||||
{
|
||||
imports = [ ];
|
||||
|
||||
config = lib.mkIf config.me.graphical {
|
||||
environment.systemPackages = with pkgs; [
|
||||
system76-keyboard-configurator
|
||||
dfu-programmer # For flashing keyboard https://support.system76.com/articles/launch_2-firmware-update/
|
||||
avrdude # For flashing keyboard https://support.system76.com/articles/launch_2-firmware-update/
|
||||
lxqt.lxqt-policykit # Need a polkit agent to launch the keyboard configurator
|
||||
];
|
||||
|
||||
systemd = {
|
||||
user.services.lxqt-policykit-agent = {
|
||||
description = "lxqt-policykit-agent";
|
||||
wantedBy = [ "graphical-session.target" ];
|
||||
wants = [ "graphical-session.target" ];
|
||||
after = [ "graphical-session.target" ];
|
||||
serviceConfig = {
|
||||
Type = "simple";
|
||||
ExecStart = "${pkgs.lxqt.lxqt-policykit}/bin/lxqt-policykit-agent";
|
||||
Restart = "on-failure";
|
||||
RestartSec = 1;
|
||||
TimeoutStopSec = 10;
|
||||
};
|
||||
};
|
||||
options.me = {
|
||||
launch_keyboard.enable = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
example = true;
|
||||
description = "Whether we want to install launch_keyboard.";
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf config.me.launch_keyboard.enable (
|
||||
lib.mkMerge [
|
||||
(lib.mkIf config.me.graphical {
|
||||
environment.systemPackages = with pkgs; [
|
||||
system76-keyboard-configurator
|
||||
dfu-programmer # For flashing keyboard https://support.system76.com/articles/launch_2-firmware-update/
|
||||
avrdude # For flashing keyboard https://support.system76.com/articles/launch_2-firmware-update/
|
||||
lxqt.lxqt-policykit # Need a polkit agent to launch the keyboard configurator
|
||||
];
|
||||
|
||||
systemd = {
|
||||
user.services.lxqt-policykit-agent = {
|
||||
description = "lxqt-policykit-agent";
|
||||
wantedBy = [ "graphical-session.target" ];
|
||||
wants = [ "graphical-session.target" ];
|
||||
after = [ "graphical-session.target" ];
|
||||
serviceConfig = {
|
||||
Type = "simple";
|
||||
ExecStart = "${pkgs.lxqt.lxqt-policykit}/bin/lxqt-policykit-agent";
|
||||
Restart = "on-failure";
|
||||
RestartSec = 1;
|
||||
TimeoutStopSec = 10;
|
||||
};
|
||||
};
|
||||
};
|
||||
})
|
||||
]
|
||||
);
|
||||
}
|
||||
|
@ -8,26 +8,36 @@
|
||||
{
|
||||
imports = [ ];
|
||||
|
||||
config = lib.mkMerge [
|
||||
{
|
||||
services.fwupd.enable = true;
|
||||
options.me = {
|
||||
lvfs.enable = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
example = true;
|
||||
description = "Whether we want to install lvfs.";
|
||||
};
|
||||
};
|
||||
|
||||
environment.persistence."/persist" = lib.mkIf (!config.me.buildingIso) {
|
||||
hideMounts = true;
|
||||
directories = [
|
||||
{
|
||||
directory = "/var/lib/fwupd";
|
||||
user = "root";
|
||||
group = "root";
|
||||
mode = "0755";
|
||||
}
|
||||
config = lib.mkIf config.me.lvfs.enable (
|
||||
lib.mkMerge [
|
||||
{
|
||||
services.fwupd.enable = true;
|
||||
environment.persistence."/persist" = lib.mkIf (!config.me.buildingIso) {
|
||||
hideMounts = true;
|
||||
directories = [
|
||||
{
|
||||
directory = "/var/lib/fwupd";
|
||||
user = "root";
|
||||
group = "root";
|
||||
mode = "0755";
|
||||
}
|
||||
];
|
||||
};
|
||||
}
|
||||
(lib.mkIf config.me.graphical {
|
||||
environment.systemPackages = with pkgs; [
|
||||
gnome-firmware
|
||||
];
|
||||
};
|
||||
}
|
||||
(lib.mkIf config.me.graphical {
|
||||
environment.systemPackages = with pkgs; [
|
||||
gnome-firmware
|
||||
];
|
||||
})
|
||||
];
|
||||
})
|
||||
]
|
||||
);
|
||||
}
|
||||
|
@ -21,20 +21,21 @@ in
|
||||
{
|
||||
imports = [ ];
|
||||
|
||||
config = (
|
||||
options.me = {
|
||||
media.enable = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = false;
|
||||
example = true;
|
||||
description = "Whether we want to install media.";
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf config.me.media.enable (
|
||||
lib.mkMerge [
|
||||
{
|
||||
environment.systemPackages = with pkgs; [
|
||||
ffmpeg
|
||||
];
|
||||
|
||||
home-manager.users.talexander =
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
home.file.".config/mpv/mpv.conf" = {
|
||||
source = ./files/mpv.conf;
|
||||
};
|
||||
};
|
||||
}
|
||||
(lib.mkIf config.me.graphical {
|
||||
environment.systemPackages = with pkgs; [
|
||||
@ -44,6 +45,14 @@ in
|
||||
# So far I prefer imv over swayimg because imv supports the 'p' hotkey to print the currently-viewed file to stdout (useful for pipelines) and afaik doesn't support the exec:// protocol which seems like a massive risk.
|
||||
imv
|
||||
];
|
||||
|
||||
home-manager.users.talexander =
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
home.file.".config/mpv/mpv.conf" = {
|
||||
source = ./files/mpv.conf;
|
||||
};
|
||||
};
|
||||
})
|
||||
(lib.mkIf (config.me.graphics_card_type == "amd" || config.me.graphics_card_type == "intel") {
|
||||
environment.systemPackages = with pkgs; [
|
||||
|
Loading…
x
Reference in New Issue
Block a user