Mac updates galore

Patch up my new structure to support Macs as well
Add Firefox for Mac overlay
Combine Python version definitions
Toy around with Vim settings
This commit is contained in:
greg-compass
2022-11-01 09:15:43 -05:00
parent 2f7b36d42d
commit 92cdb0fc05
9 changed files with 99 additions and 63 deletions
Generated
+35
View File
@@ -39,6 +39,24 @@
"type": "github" "type": "github"
} }
}, },
"ffmac": {
"inputs": {
"nixpkgs": "nixpkgs_2"
},
"locked": {
"lastModified": 1666832804,
"narHash": "sha256-RodK149KQi2k5JtmjtFaPDSKvklRyTR3+DhWFTZNn2k=",
"owner": "bandithedoge",
"repo": "nixpkgs-firefox-darwin",
"rev": "19b6537ac95a2402e850799a52e3c8ed62f2db2a",
"type": "github"
},
"original": {
"owner": "bandithedoge",
"repo": "nixpkgs-firefox-darwin",
"type": "github"
}
},
"home-manager": { "home-manager": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
@@ -76,6 +94,22 @@
"type": "github" "type": "github"
} }
}, },
"nixpkgs_2": {
"locked": {
"lastModified": 1639237670,
"narHash": "sha256-RTdL4rEQcgaZGpvtDgkp3oK/V+1LM3I53n0ACPSroAQ=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "edfb969386ebe6c3cf8f878775a7975cd88f926d",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "master",
"repo": "nixpkgs",
"type": "github"
}
},
"nixunstable": { "nixunstable": {
"locked": { "locked": {
"lastModified": 1665848363, "lastModified": 1665848363,
@@ -111,6 +145,7 @@
"inputs": { "inputs": {
"agenix": "agenix", "agenix": "agenix",
"darwin": "darwin", "darwin": "darwin",
"ffmac": "ffmac",
"home-manager": "home-manager", "home-manager": "home-manager",
"nixunstable": "nixunstable", "nixunstable": "nixunstable",
"nurpkgs": "nurpkgs", "nurpkgs": "nurpkgs",
+19 -12
View File
@@ -17,6 +17,7 @@
inputs.nixpkgs.follows = "nixunstable"; inputs.nixpkgs.follows = "nixunstable";
}; };
nurpkgs.url = "github:nix-community/NUR"; nurpkgs.url = "github:nix-community/NUR";
ffmac.url = "github:bandithedoge/nixpkgs-firefox-darwin";
}; };
outputs = {stable, nixunstable, agenix, home-manager, nurpkgs, self, ...}@inputs: outputs = {stable, nixunstable, agenix, home-manager, nurpkgs, self, ...}@inputs:
@@ -26,14 +27,7 @@
agenix.overlay agenix.overlay
local_overlay local_overlay
nurpkgs.overlay nurpkgs.overlay
]; inputs.ffmac.overlay
darwinMods = hostname: [
{ stable.overlays = overlays; }
inputs.agenix.nixosModule
./modules-all
./modules-darwin
./hosts/${hostname}
]; ];
machine = { machine = {
@@ -84,11 +78,24 @@
"iso" = machine { name = "iso"; }; "iso" = machine { name = "iso"; };
}; };
darwinConfigurations = { darwinConfigurations =
let
nixpkgs = stable {
overlays = overlays;
};
in {
"C02G48H8MD6R" = inputs.darwin.lib.darwinSystem { "C02G48H8MD6R" = inputs.darwin.lib.darwinSystem {
system = "x86_64-darwin"; system = "x86_64-darwin";
specialArgs = inputs; specialArgs = {
modules = darwinMods "work"; nixpkgs = stable;
};
modules = [
{ nixpkgs.overlays = overlays; }
inputs.agenix.nixosModule
./modules-all
./modules-darwin
./hosts/work
];
}; };
}; };
@@ -97,7 +104,7 @@
homeConfigurations = ( homeConfigurations = (
import ./home { import ./home {
inherit nixunstable agenix home-manager nurpkgs; inherit nixunstable agenix home-manager overlays;
nixpkgs = nixunstable; nixpkgs = nixunstable;
} }
); );
+9 -12
View File
@@ -1,4 +1,10 @@
{ nixpkgs, nurpkgs, home-manager, username ? builtins.getEnv "USER", ... }: {
nixpkgs,
overlays,
home-manager,
username ? builtins.getEnv "USER",
...
}:
let let
home = system: home = system:
@@ -12,25 +18,16 @@ let
configDir = "${homeDirectory}/.config"; configDir = "${homeDirectory}/.config";
pkgs = import nixpkgs { pkgs = import nixpkgs {
inherit overlays;
config.allowUnfree = true; config.allowUnfree = true;
config.xdg.configHome = configDir; config.xdg.configHome = configDir;
overlays = [
nurpkgs.overlay
(import ../overlays)
];
}; };
nur = import nurpkgs {
inherit pkgs;
nur = pkgs;
};
in home-manager.lib.homeManagerConfiguration rec { in home-manager.lib.homeManagerConfiguration rec {
inherit pkgs system username homeDirectory; inherit pkgs system username homeDirectory;
stateVersion = "22.05"; stateVersion = "22.05";
configuration = import ./home.nix username { configuration = import ./home.nix username {
inherit nur pkgs gui; inherit pkgs gui;
inherit (pkgs) config lib stdenv; inherit (pkgs) config lib stdenv;
}; };
}; };
+1 -1
View File
@@ -10,7 +10,6 @@
home.packages = with pkgs; [ home.packages = with pkgs; [
gopls gopls
jellyfin-media-player
synology-drive-client synology-drive-client
zoom-us zoom-us
] ++ ( if pkgs.system == "x86_64-darwin" then ] ++ ( if pkgs.system == "x86_64-darwin" then
@@ -21,6 +20,7 @@
bitwarden bitwarden
gnucash gnucash
handbrake handbrake
jellyfin-media-player
nextcloud-client nextcloud-client
onlyoffice-bin onlyoffice-bin
vlc vlc
+4 -2
View File
@@ -3,7 +3,7 @@
let let
# For now, we ignore this and don't install it # For now, we ignore this and don't install it
ffPkgs = if ( lib.hasSuffix "-darwin" pkgs.system ) ffPkgs = if ( lib.hasSuffix "-darwin" pkgs.system )
then pkgs.firefox-unwrapped then pkgs.firefox-bin
else pkgs.firefox-wayland.override { cfg.enableGnomeExtensions = true; }; else pkgs.firefox-wayland.override { cfg.enableGnomeExtensions = true; };
vars = { vars = {
@@ -13,7 +13,7 @@ let
in with lib; in with lib;
{ {
programs.firefox = { programs.firefox = {
enable = (if (lib.hasSuffix "-darwin" pkgs.system) then false else true); enable = true;
package = ffPkgs; package = ffPkgs;
extensions = with pkgs.nur.repos.rycee.firefox-addons; [ extensions = with pkgs.nur.repos.rycee.firefox-addons; [
bitwarden bitwarden
@@ -25,10 +25,12 @@ in with lib;
]; ];
profiles = { profiles = {
default.settings = { default.settings = {
"app.update.auto" = false;
"browser.startup.page" = 3; "browser.startup.page" = 3;
"browser.startup.homepage" = "https://thehellings.com"; "browser.startup.homepage" = "https://thehellings.com";
"doh-rollout.doorhanger-decision" = "UIDisabled"; "doh-rollout.doorhanger-decision" = "UIDisabled";
"doh-rollout.doneFirstRun" = true; "doh-rollout.doneFirstRun" = true;
"signon.rememberSignons" = false;
}; };
}; };
}; };
+2 -21
View File
@@ -4,25 +4,6 @@ let
guiImports = if gui then guiImports = if gui then
[ ./gui ] else []; [ ./gui ] else [];
myPackages = pypackages: with pypackages; with pkgs.my-py-addons; [
black
copier
datadog
datadog-api-client
dateutil
flake8
ipython
pyyaml
responses
ruamel-yaml
tox
typing-extensions
virtualenv
xonsh-direnv
];
myPython = pkgs.python3.withPackages myPackages;
in { in {
imports = [ imports = [
./modules ./modules
@@ -61,12 +42,12 @@ in {
gh gh
git git
gnupatch gnupatch
gregpy
hms hms
htop htop
jdk11 jdk11
jq jq
libtheora libtheora
myPython
nmap nmap
nano nano
openssl openssl
@@ -76,6 +57,6 @@ in {
wget wget
x265 x265
yamllint yamllint
yawsso #yawsso
]; ];
} }
+6 -6
View File
@@ -75,12 +75,12 @@ let g:ctrlp_working_path_mode = 'arc'
let g:ctrlp_switch_buffer = 0 let g:ctrlp_switch_buffer = 0
let g:ctrlp_cmd = 'CtrlPMixed' let g:ctrlp_cmd = 'CtrlPMixed'
let g:ctrlp_show_hidden = 1 let g:ctrlp_show_hidden = 1
"let g:ctrlp_user_command = { let g:ctrlp_user_command = {
" \'types': { \'types': {
" \1: ['.git', '${pkgs.git}/bin/git ls-files --cached --exclude-standard --others' ], \1: ['.git', '${pkgs.git}/bin/git ls-files --cached --exclude-standard --others' ],
" \}, \},
" \'fallback': '${pkgs.findutils}/bin/find . -type f | ${pkgs.gnugrep}/bin/grep -v -e "\.tox/" -e "\.git/"' \'fallback': '${pkgs.findutils}/bin/find . -type f | ${pkgs.gnugrep}/bin/grep -v -e "\.tox/" -e "\.git/"',
"\} \}
" let g:ctrpl_match_func = { 'match': 'pymatcher#PyMatch' } " let g:ctrpl_match_func = { 'match': 'pymatcher#PyMatch' }
" Settings for NerdTree " Settings for NerdTree
+2 -9
View File
@@ -1,13 +1,6 @@
{ pkgs, ... }: { pkgs, ... }:
let {
myPackages = pypackages: with pypackages; [
pkgs.my-py-addons.xonsh-direnv
virtualenv
];
myPython = pkgs.python3.withPackages myPackages;
in {
# Base packages that need to be in all my hosts # Base packages that need to be in all my hosts
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
agenix agenix
@@ -16,11 +9,11 @@ in {
diffutils diffutils
git git
gnupatch gnupatch
gregpy
findutils findutils
hms # My own home manager switcher hms # My own home manager switcher
home-manager home-manager
htop htop
myPython
nano nano
pwgen pwgen
transcrypt transcrypt
+21
View File
@@ -3,7 +3,28 @@ self: super:
let let
cp = super.python3.pkgs.callPackage; cp = super.python3.pkgs.callPackage;
myPackages = pypackages: with pypackages; with pkgs.my-py-addons; [
black
copier
datadog
datadog-api-client
dateutil
flake8
ipython
pyyaml
responses
ruamel-yaml
tox
typing-extensions
virtualenv
xonsh-direnv
];
myPython = super.python3.withPackages myPackages;
in rec { in rec {
gregpy = myPython;
my-py-addons = rec { my-py-addons = rec {
copier = cp ./copier.nix { copier = cp ./copier.nix {
inherit iteration-utilities inherit iteration-utilities