Update stdenv.isLinux and stdenv.isDarwin calls

This commit is contained in:
2026-08-31 20:30:05 +02:00
parent 08c2eb8bfe
commit daf7eb8d75
6 changed files with 13 additions and 13 deletions
+2 -2
View File
@@ -58,7 +58,7 @@ in {
in
lib.mkMerge [
# Darwin exclusive config
(lib.mkIf pkgs.stdenv.isDarwin {
(lib.mkIf pkgs.stdenv.hostPlatform.isDarwin {
shellInit = ''
set fish_greeting
yes | fish_config theme save "system-theme"
@@ -81,7 +81,7 @@ in {
})
# Linux exclusive config
(lib.mkIf pkgs.stdenv.isLinux {
(lib.mkIf pkgs.stdenv.hostPlatform.isLinux {
generateCompletions = nixosConfig.programs.fish.generateCompletions;
# TODO: There's a bug with the direnv mechanism:
+4 -4
View File
@@ -10,7 +10,7 @@
inherit (config.homemodules) jellyfin-tui color;
systemConfig =
if pkgs.stdenv.isLinux
if pkgs.stdenv.hostPlatform.isLinux
then nixosConfig
else darwinConfig;
in {
@@ -24,7 +24,7 @@ in {
file = let
jellyfinUrl =
if pkgs.stdenv.isLinux
if pkgs.stdenv.hostPlatform.isLinux
then "https://jellyfin.local.chriphost.de"
else "https://jellyfin.vps.chriphost.de";
@@ -79,10 +79,10 @@ in {
'';
in
lib.mkMerge [
(lib.optionalAttrs pkgs.stdenv.isLinux {
(lib.optionalAttrs pkgs.stdenv.hostPlatform.isLinux {
".config/jellyfin-tui/config.yaml".text = configFile;
})
(lib.optionalAttrs pkgs.stdenv.isDarwin {
(lib.optionalAttrs pkgs.stdenv.hostPlatform.isDarwin {
"Library/Application Support/jellyfin-tui/config.yaml".text = configFile;
})
];
+1 -1
View File
@@ -36,7 +36,7 @@ in {
settings = lib.mkMerge [
# Linux config
(lib.mkIf pkgs.stdenv.isLinux {
(lib.mkIf pkgs.stdenv.hostPlatform.isLinux {
allow_remote_control = true; # For nnn file preview or nvim scrollback
listen_on = lib.mkDefault "unix:@mykitty"; # This conflicts with direnv-instant
})
+3 -3
View File
@@ -81,7 +81,7 @@ in {
])
# Linux exclusive packages
(lib.optionals (pkgs.stdenv.isLinux) [
(lib.optionals (pkgs.stdenv.hostPlatform.isLinux) [
pastel # Color tools
nvd # Nix rebuild diff
nurl # Generate nix fetcher sections based on URLs
@@ -139,7 +139,7 @@ in {
])
# Linux exclusive packages (!headless)
(lib.optionals (pkgs.stdenv.isLinux && (!headless)) [
(lib.optionals (pkgs.stdenv.hostPlatform.isLinux && (!headless)) [
wl-clipboard
asciicam
@@ -192,7 +192,7 @@ in {
])
# Darwin exclusive packages
(lib.optionals pkgs.stdenv.isDarwin [
(lib.optionals pkgs.stdenv.hostPlatform.isDarwin [
# Use homebrew instead
# alt-tab-macos
# discord
+1 -1
View File
@@ -19,7 +19,7 @@ in {
"*" = {
ForwardAgent = false;
AddKeysToAgent =
if pkgs.stdenv.isLinux
if pkgs.stdenv.hostPlatform.isLinux
then "no"
else "yes"; # Don't have keychain on darwin
Compression = true;
+2 -2
View File
@@ -34,11 +34,11 @@ in {
secrets = let
mkSecret = name: {
${name} = lib.mkMerge [
(lib.optionalAttrs pkgs.stdenv.isLinux {
(lib.optionalAttrs pkgs.stdenv.hostPlatform.isLinux {
owner = config.users.users.${username}.name;
group = config.users.users.${username}.group;
})
(lib.optionalAttrs pkgs.stdenv.isDarwin {
(lib.optionalAttrs pkgs.stdenv.hostPlatform.isDarwin {
owner = config.users.users.${username}.name;
group = "staff"; # Apparently there's no way to get the primary group?
})