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