Compare commits

..

13 commits

5 changed files with 83 additions and 11 deletions

33
flake.lock generated
View file

@ -43,6 +43,26 @@
"type": "github" "type": "github"
} }
}, },
"home-manager-unstable": {
"inputs": {
"nixpkgs": [
"nixpkgs-unstable"
]
},
"locked": {
"lastModified": 1687647343,
"narHash": "sha256-1/o/i9KEFOBdlF9Cs04kBcqDFbYMt6W4SMqGa+QnnaI=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "0ee5ab611dc1fbb5180bd7d88d2aeb7841a4d179",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "home-manager",
"type": "github"
}
},
"home-manager_2": { "home-manager_2": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
@ -50,11 +70,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1687041925, "lastModified": 1687163790,
"narHash": "sha256-Zfn/SphInZ9PEIHWdQk+wGQ0XGlwAgRUp/Qso+8vDOY=", "narHash": "sha256-CmG/ZdswJrWM0CMgJiVyWfO6LqaI4SKEAx9IrnYDrpI=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "a8d549351d4b87ab80665f35e57bee2a04201245", "rev": "ac53777f52929bc82efcd2830bfc5aa60bcb4337",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -81,11 +101,11 @@
}, },
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1686921029, "lastModified": 1687379288,
"narHash": "sha256-J1bX9plPCFhTSh6E3TWn9XSxggBh/zDD4xigyaIQBy8=", "narHash": "sha256-cSuwfiqYfeVyqzCRkU9AvLTysmEuSal8nh6CYr+xWog=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "c7ff1b9b95620ce8728c0d7bd501c458e6da9e04", "rev": "ef0bc3976340dab9a4e087a0bcff661a8b2e87f3",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -113,6 +133,7 @@
"inputs": { "inputs": {
"agenix": "agenix", "agenix": "agenix",
"home-manager": "home-manager_2", "home-manager": "home-manager_2",
"home-manager-unstable": "home-manager-unstable",
"nix-impermanence": "nix-impermanence", "nix-impermanence": "nix-impermanence",
"nixpkgs": "nixpkgs", "nixpkgs": "nixpkgs",
"nixpkgs-unstable": "nixpkgs-unstable" "nixpkgs-unstable": "nixpkgs-unstable"

View file

@ -13,13 +13,20 @@ agenix = {
}; };
}; };
home-manager.url = "github:nix-community/home-manager/release-23.05"; home-manager = {
home-manager.inputs.nixpkgs.follows = "nixpkgs"; url = "github:nix-community/home-manager/release-23.05";
inputs.nixpkgs.follows = "nixpkgs";
};
home-manager-unstable = {
url = "github:nix-community/home-manager/";
inputs.nixpkgs.follows = "nixpkgs-unstable";
};
nix-impermanence.url = "github:nix-community/impermanence"; nix-impermanence.url = "github:nix-community/impermanence";
}; };
outputs = {nixpkgs, agenix, home-manager, nixpkgs-unstable, nix-impermanence, ... }: { outputs = {nixpkgs, nixpkgs-unstable, agenix, home-manager, home-manager-unstable, nix-impermanence, ... }: {
devShells.x86_64-linux.default = nixpkgs.legacyPackages.x86_64-linux.mkShell { devShells.x86_64-linux.default = nixpkgs.legacyPackages.x86_64-linux.mkShell {
name = "Environment for toast's nixos configurations"; name = "Environment for toast's nixos configurations";
# The agenix cli is not needed to activate a configuration, so instead of installing it # The agenix cli is not needed to activate a configuration, so instead of installing it
@ -55,7 +62,7 @@ outputs = {nixpkgs, agenix, home-manager, nixpkgs-unstable, nix-impermanence, ..
# Needed for nix-index # Needed for nix-index
{ nix.nixPath = [ "nixpkgs=${nixpkgs}" ]; } { nix.nixPath = [ "nixpkgs=${nixpkgs}" ]; }
agenix.nixosModules.default agenix.nixosModules.default
home-manager.nixosModule home-manager-unstable.nixosModule
./roles/common ./roles/common
./roles/desktop ./roles/desktop
./roles/kde ./roles/kde

View file

@ -65,7 +65,6 @@
isNormalUser = true; isNormalUser = true;
extraGroups = [ "wheel" ]; # Enable sudo for the user. extraGroups = [ "wheel" ]; # Enable sudo for the user.
packages = with pkgs; [ packages = with pkgs; [
firefox
tree tree
]; ];
}; };

View file

@ -3,5 +3,6 @@
{ {
imports = [ imports = [
./discord.nix ./discord.nix
./firefox.nix
]; ];
} }

44
roles/desktop/firefox.nix Normal file
View file

@ -0,0 +1,44 @@
{ config, pkgs, ... }:
{
# System wide firefox settings
programs.firefox = {
enable = true;
policies = {
"DisablePocket" = true;
"DisableTelemetry" = true;
# You need these for Spotify
"EncryptedMediaExtensions" = { "Enabled" = true; };
"ExtensionSettings" = {
# TODO: Install extensions the NUR instead of from AMO
"uBlock0@raymondhill.net" = {
"installation_mode" = "force_installed";
"install_url" = "https://addons.mozilla.org/firefox/downloads/latest/ublock-origin/latest.xpi";
};
# Decentraleyes
"jid1-BoFifL9Vbdl2zQ@jetpack" = {
"installation_mode" = "normal_installed";
"install_url" = "https://addons.mozilla.org/firefox/downloads/latest/decentraleyes/latest.xpi";
};
"jid1-MnnxcxisBPnSXQ@jetpack" = {
"installation_mode" = "normal_installed";
"install_url" = "https://addons.mozilla.org/firefox/downloads/latest/privacy-badger17/latest.xpi";
};
};
"Preferences" = {
# Enable video hardware acceleration
"media.ffmpeg.vaapi.enabled" = {
"Value" = true;
"Status" = "default";
};
};
"Permissions" = {
"Autoplay" = {
"Allow" = [ "https://www.youtube.com" ];
"Default" = "block-audio-video";
};
};
"FirefoxHome" = { "SponsoredTopSites" = false; };
};
};
}