Compare commits

5 Commits

6 changed files with 121 additions and 27 deletions

83
flake.lock generated
View File

@@ -1,5 +1,39 @@
{
"nodes": {
"dotfiles": {
"flake": false,
"locked": {
"lastModified": 1743949278,
"narHash": "sha256-ntNJXtq3Gw+7ssEgLzoKAiuSS6QXaCwK6k/KSLlqBwo=",
"ref": "main",
"rev": "6e1d7df5b569f2eb98759e1ca77a06556c5bd1dd",
"revCount": 10,
"type": "git",
"url": "https://git.finally.coffee/transcaffeine/dotfiles.git"
},
"original": {
"ref": "main",
"type": "git",
"url": "https://git.finally.coffee/transcaffeine/dotfiles.git"
}
},
"dotfiles-local": {
"flake": false,
"locked": {
"lastModified": 1743949278,
"narHash": "sha256-ntNJXtq3Gw+7ssEgLzoKAiuSS6QXaCwK6k/KSLlqBwo=",
"ref": "main",
"rev": "6e1d7df5b569f2eb98759e1ca77a06556c5bd1dd",
"revCount": 10,
"type": "git",
"url": "https://git.finally.coffee/transcaffeine/dotfiles"
},
"original": {
"ref": "main",
"type": "git",
"url": "https://git.finally.coffee/transcaffeine/dotfiles"
}
},
"home-manager": {
"inputs": {
"nixpkgs": [
@@ -52,27 +86,62 @@
"type": "github"
}
},
"nixpkgs-unstable": {
"nixpkgs-forked": {
"locked": {
"lastModified": 1756787288,
"narHash": "sha256-rw/PHa1cqiePdBxhF66V7R+WAP8WekQ0mCDG4CFqT8Y=",
"owner": "NixOS",
"lastModified": 1751998018,
"narHash": "sha256-JHVI60B3/cN3a0JDfslramsO056ig5wMQTGmgO9eLWQ=",
"owner": "transcaffeine",
"repo": "nixpkgs",
"rev": "d0fc30899600b9b3466ddb260fd83deb486c32f1",
"rev": "5d91ff97e777cd2bfb8cb108907e49abcea939f4",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-unstable",
"owner": "transcaffeine",
"ref": "nexus/3.81.1",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs-local": {
"locked": {
"lastModified": 1757168979,
"narHash": "sha256-abp5DZtyu8idvMbPbEpBfdsxmhnNo/ud8hZ0KsbvAqs=",
"ref": "refs/heads/cinny/4.9.1",
"rev": "fc2627665df4f815f2409effcaf7bb0f427e303c",
"revCount": 855244,
"type": "git",
"url": "file:/home/transcaffeine/git/transcaffeine/nixpkgs"
},
"original": {
"type": "git",
"url": "file:/home/transcaffeine/git/transcaffeine/nixpkgs"
}
},
"nixpkgs-unstable": {
"locked": {
"lastModified": 1757236331,
"narHash": "sha256-zf1HPzatARa8PFLS7ypOxx2IVpbAWotKYl8Kgu4DYyw=",
"owner": "nixOS",
"repo": "nixpkgs",
"rev": "1f46efd9d12bc85e195f4d17aacc372a88a277a5",
"type": "github"
},
"original": {
"owner": "nixOS",
"ref": "master",
"repo": "nixpkgs",
"type": "github"
}
},
"root": {
"inputs": {
"dotfiles": "dotfiles",
"dotfiles-local": "dotfiles-local",
"home-manager": "home-manager",
"nixos-hardware": "nixos-hardware",
"nixpkgs": "nixpkgs",
"nixpkgs-forked": "nixpkgs-forked",
"nixpkgs-local": "nixpkgs-local",
"nixpkgs-unstable": "nixpkgs-unstable"
}
}

View File

@@ -1,14 +1,24 @@
{
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-25.05";
nixpkgs-unstable.url = "github:NixOS/nixpkgs/nixos-unstable";
# nixpkgs-unstable.url = "github:transcaffeine/nixpkgs/nexus/3.81.1";
# nixpkgs-unstable.url = "git+file:/home/transcaffeine/git/transcaffeine/nixpkgs";
nixpkgs-unstable.url = "github:nixOS/nixpkgs/master";
nixpkgs-forked.url = "github:transcaffeine/nixpkgs/nexus/3.81.1";
nixpkgs-local = {
url = "git+file:/home/transcaffeine/git/transcaffeine/nixpkgs";
};
home-manager = {
url = "github:nix-community/home-manager/release-25.05";
inputs.nixpkgs.follows = "nixpkgs";
};
nixos-hardware.url = "github:NixOS/nixos-hardware";
dotfiles = {
url = "git+https://git.finally.coffee/transcaffeine/dotfiles.git?ref=main";
flake = false;
};
dotfiles-local = {
url = "git+file:/home/transcaffeine/git/transcaffeine/dotfiles";
flake = false;
};
};
outputs = inputs @ { self, nixpkgs, nixpkgs-unstable, ... }: {

View File

@@ -2,4 +2,5 @@
imports = [ inputs.home-manager.nixosModules.home-manager ];
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.extraSpecialArgs = { inherit inputs; };
}

View File

@@ -0,0 +1,26 @@
{
inputs,
lib,
...
}:
let
genAttrs' = xs: f: lib.listToAttrs(lib.map f xs);
in {
services.darkman = {
enable = true;
settings = {
lat = 49.0800;
lng = 8.23300;
portal = true;
dbusserver = true;
};
};
home.file = genAttrs' [ "local/share/light-mode.d" "local/share/dark-mode.d" ] (
path:
lib.nameValuePair (".${path}") {
source = lib.concatStringsSep "/" [ inputs.dotfiles path ];
target = ".${path}";
}
);
}

View File

@@ -1,18 +1,10 @@
{ lib, pkgs, ... }: {
imports = [
./darkman.nix
./git.nix
./gnupg.nix
];
home.stateVersion = "24.11";
services.darkman = {
enable = true;
settings = {
lat = 49.0800;
lng = 8.23300;
portal = true;
dbusserver = true;
};
};
home.preferXdgDirectories = true;
programs.firefox = import ./firefox.nix { inherit lib; };

View File

@@ -1,11 +1,7 @@
{ lib, config, ... }:
{ inputs, lib, config, ... }:
let
repo = (builtins.fetchGit {
url = "https://git.finally.coffee/transcaffeine/dotfiles.git";
ref = "main";
shallow = true;
});
dotfileRepo = inputs.dotfiles;
utils = import ../../../utils { inherit lib; };
in {
programs.gpg = let
@@ -16,7 +12,7 @@ in {
}) (
builtins.filter (value: value != "") (
lib.splitString "\n" (
lib.readFile (repo.outPath + "/config/gnupg/gpg.conf")
lib.readFile (dotfileRepo + "/config/gnupg/gpg.conf")
)
)
)
@@ -36,7 +32,7 @@ in {
}) (
builtins.filter (v: v != "") (
lib.splitString "\n" (
lib.readFile (repo.outPath + "/config/gnupg/gpg-agent.conf")
lib.readFile (dotfileRepo.outPath + "/config/gnupg/gpg-agent.conf")
)
)
)