initial setup for home-manager on darwin
This commit is contained in:
parent
eec7f91843
commit
5524721426
4 changed files with 65 additions and 9 deletions
22
flake.lock
22
flake.lock
|
@ -33,6 +33,27 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"darwin": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1686210161,
|
||||
"narHash": "sha256-cgP8P2Gk4WtOzd/Y7nEmweLpPOtMKVvHCIcq9zm9qMk=",
|
||||
"owner": "lnl7",
|
||||
"repo": "nix-darwin",
|
||||
"rev": "40e4b85baac86969f94d6dba893aeae015c562c1",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "lnl7",
|
||||
"ref": "master",
|
||||
"repo": "nix-darwin",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-compat": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
|
@ -289,6 +310,7 @@
|
|||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"darwin": "darwin",
|
||||
"home-manager": "home-manager",
|
||||
"impermanence": "impermanence",
|
||||
"lanzaboote": "lanzaboote",
|
||||
|
|
34
flake.nix
34
flake.nix
|
@ -6,6 +6,9 @@
|
|||
url = "github:NixOS/nixpkgs/nixos-unstable";
|
||||
};
|
||||
|
||||
darwin.url = "github:lnl7/nix-darwin/master";
|
||||
darwin.inputs.nixpkgs.follows = "nixpkgs";
|
||||
|
||||
home-manager = {
|
||||
url = "github:nix-community/home-manager";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
|
@ -29,20 +32,24 @@
|
|||
outputs = {
|
||||
self,
|
||||
nixpkgs,
|
||||
darwin,
|
||||
home-manager,
|
||||
impermanence,
|
||||
lanzaboote,
|
||||
nixneovimplugins,
|
||||
} @ inputs: {
|
||||
formatter."x86_64-linux" = nixpkgs.legacyPackages."x86_64-linux".alejandra;
|
||||
nixosConfigurations = let
|
||||
} @ inputs: let
|
||||
user = (import ./secrets.nix).users;
|
||||
in {
|
||||
formatter."x86_64-linux" = nixpkgs.legacyPackages."x86_64-linux".alejandra;
|
||||
formatter."x86_64-darwin" = nixpkgs.legacyPackages."x86_64-darwin".alejandra;
|
||||
nixosConfigurations = {
|
||||
Skipper = nixpkgs.lib.nixosSystem rec {
|
||||
system = "x86_64-linux";
|
||||
pkgs = import nixpkgs {
|
||||
inherit system;
|
||||
config = {allowUnfree = true;};
|
||||
config = {
|
||||
allowUnfree = true;
|
||||
};
|
||||
overlays = [(import ./packages) nixneovimplugins.overlays.default];
|
||||
};
|
||||
specialArgs = inputs;
|
||||
|
@ -76,7 +83,9 @@
|
|||
system = "aarch64-linux";
|
||||
pkgs = import nixpkgs {
|
||||
inherit system;
|
||||
config = {allowUnfree = true;};
|
||||
config = {
|
||||
allowUnfree = true;
|
||||
};
|
||||
};
|
||||
specialArgs = inputs;
|
||||
modules = [
|
||||
|
@ -88,5 +97,20 @@
|
|||
];
|
||||
};
|
||||
};
|
||||
homeConfigurations."${user.primary.userName}@Alex" = home-manager.lib.homeManagerConfiguration {
|
||||
pkgs = import nixpkgs {
|
||||
system = "x86_64-darwin";
|
||||
config = {
|
||||
allowUnfree = true;
|
||||
};
|
||||
overlays = [nixneovimplugins.overlays.default];
|
||||
};
|
||||
|
||||
# Specify your home configuration modules here, for example,
|
||||
# the path to your home.nix.
|
||||
modules = [
|
||||
(import ./home/darwin.nix {inherit user;})
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
10
home/darwin.nix
Normal file
10
home/darwin.nix
Normal file
|
@ -0,0 +1,10 @@
|
|||
{user, ...}: {
|
||||
home = {
|
||||
username = user.primary.userName;
|
||||
homeDirectory = "/Users/${user.primary.userName}";
|
||||
stateVersion = "23.11";
|
||||
};
|
||||
programs.home-manager.enable = true;
|
||||
|
||||
imports = [./programs/neovim.nix];
|
||||
}
|
|
@ -1,7 +1,7 @@
|
|||
{pkgs, ...}: {
|
||||
xdg.desktopEntries."nvim".name = "Neovim wrapper";
|
||||
xdg.desktopEntries."nvim".exec = "nvim %F";
|
||||
xdg.desktopEntries."nvim".noDisplay = true;
|
||||
#xdg.desktopEntries."nvim".name = "Neovim wrapper";
|
||||
#xdg.desktopEntries."nvim".exec = "nvim %F";
|
||||
#xdg.desktopEntries."nvim".noDisplay = true;
|
||||
|
||||
programs.neovim = {
|
||||
enable = true;
|
||||
|
|
Loading…
Reference in a new issue