From 1d996a406721d0e939adbf64e09bc5511e7f88bc Mon Sep 17 00:00:00 2001 From: Jonni Liljamo Date: Thu, 5 Sep 2024 20:41:26 +0300 Subject: [PATCH] feat: add tamma to devshell, init config --- flake.lock | 155 ++++++++++++++++++++++++++++++++++++++++++++++++++++- flake.nix | 4 ++ tamma.yaml | 7 +++ 3 files changed, 165 insertions(+), 1 deletion(-) create mode 100644 tamma.yaml diff --git a/flake.lock b/flake.lock index 12d1e6f..266b0e4 100644 --- a/flake.lock +++ b/flake.lock @@ -53,6 +53,22 @@ "url": "https://flakehub.com/f/edolstra/flake-compat/1.tar.gz" } }, + "flake-compat_3": { + "flake": false, + "locked": { + "lastModified": 1696426674, + "narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=", + "owner": "edolstra", + "repo": "flake-compat", + "rev": "0f9255e01c2351cc7d116c072cb317785dd33b33", + "type": "github" + }, + "original": { + "owner": "edolstra", + "repo": "flake-compat", + "type": "github" + } + }, "flake-parts": { "inputs": { "nixpkgs-lib": [ @@ -131,6 +147,24 @@ "type": "github" } }, + "flake-utils_2": { + "inputs": { + "systems": "systems_2" + }, + "locked": { + "lastModified": 1710146030, + "narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=", + "owner": "numtide", + "repo": "flake-utils", + "rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "flake-utils", + "type": "github" + } + }, "git-hooks": { "inputs": { "flake-compat": "flake-compat", @@ -233,6 +267,28 @@ "type": "github" } }, + "gitignore_3": { + "inputs": { + "nixpkgs": [ + "tamma", + "pre-commit-hooks", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1709087332, + "narHash": "sha256-HG2cCnktfHsKV0s4XW83gU3F57gaTljL9KNSuG6bnQs=", + "owner": "hercules-ci", + "repo": "gitignore.nix", + "rev": "637db329424fd7e46cf4185293b9cc8c88c95394", + "type": "github" + }, + "original": { + "owner": "hercules-ci", + "repo": "gitignore.nix", + "type": "github" + } + }, "home-manager": { "inputs": { "nixpkgs": [ @@ -356,6 +412,22 @@ "url": "https://github.com/NixOS/nixpkgs/archive/5daf0514482af3f97abaefc78a6606365c9108e2.tar.gz" } }, + "nixpkgs-stable": { + "locked": { + "lastModified": 1710695816, + "narHash": "sha256-3Eh7fhEID17pv9ZxrPwCLfqXnYP006RKzSs0JptsN84=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "614b4613980a522ba49f0d194531beddbb7220d3", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-23.11", + "repo": "nixpkgs", + "type": "github" + } + }, "nixpkgs-unstable": { "locked": { "lastModified": 1720542800, @@ -372,6 +444,22 @@ "type": "github" } }, + "nixpkgs_2": { + "locked": { + "lastModified": 1713254108, + "narHash": "sha256-0TZIsfDbHG5zibtlw6x0yOp3jkInIGaJ35B7Y4G8Pec=", + "owner": "nixos", + "repo": "nixpkgs", + "rev": "2fd19c8be2551a61c1ddc3d9f86d748f4db94f00", + "type": "github" + }, + "original": { + "owner": "nixos", + "ref": "nixpkgs-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, "nixvim": { "inputs": { "devshell": "devshell", @@ -422,6 +510,34 @@ "url": "https://git.src.quest/~liljamo/nvim-flake" } }, + "pre-commit-hooks": { + "inputs": { + "flake-compat": "flake-compat_3", + "flake-utils": [ + "tamma", + "flake-utils" + ], + "gitignore": "gitignore_3", + "nixpkgs": [ + "tamma", + "nixpkgs" + ], + "nixpkgs-stable": "nixpkgs-stable" + }, + "locked": { + "lastModified": 1712897695, + "narHash": "sha256-nMirxrGteNAl9sWiOhoN5tIHyjBbVi5e2tgZUgZlK3Y=", + "owner": "cachix", + "repo": "pre-commit-hooks.nix", + "rev": "40e6053ecb65fcbf12863338a6dcefb3f55f1bf8", + "type": "github" + }, + "original": { + "owner": "cachix", + "repo": "pre-commit-hooks.nix", + "type": "github" + } + }, "root": { "inputs": { "flake-parts": "flake-parts", @@ -432,7 +548,8 @@ "nixpkgs": "nixpkgs", "nixpkgs-unstable": "nixpkgs-unstable", "nvim-flake": "nvim-flake", - "sops-nix": "sops-nix" + "sops-nix": "sops-nix", + "tamma": "tamma" } }, "sops-nix": { @@ -473,6 +590,42 @@ "type": "github" } }, + "systems_2": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } + }, + "tamma": { + "inputs": { + "flake-utils": "flake-utils_2", + "nixpkgs": "nixpkgs_2", + "pre-commit-hooks": "pre-commit-hooks" + }, + "locked": { + "lastModified": 1725557675, + "narHash": "sha256-FmnlgBLJ480Z9e7p1CltZ4znLTm/cZdIbbE2hhmmnqQ=", + "ref": "refs/tags/0.1.2", + "rev": "c524c033bdfdf82aacde1df02bab049f772efe3c", + "revCount": 6, + "type": "git", + "url": "https://git.src.quest/~liljamo/tamma" + }, + "original": { + "ref": "refs/tags/0.1.2", + "type": "git", + "url": "https://git.src.quest/~liljamo/tamma" + } + }, "treefmt-nix": { "inputs": { "nixpkgs": [ diff --git a/flake.nix b/flake.nix index 6e3c9c8..74a7f1c 100644 --- a/flake.nix +++ b/flake.nix @@ -30,6 +30,7 @@ }; # Own flakes + tamma.url = "git+https://git.src.quest/~liljamo/tamma?ref=refs/tags/0.1.2"; nvim-flake = { url = "git+https://git.src.quest/~liljamo/nvim-flake"; inputs.nixpkgs.follows = "nixpkgs-unstable"; @@ -64,6 +65,9 @@ alejandra sops ] + ++ [ + inputs.tamma.packages.${system}.default + ] ++ self.checks.${system}.pre-commit-check.enabledPackages; }; }; diff --git a/tamma.yaml b/tamma.yaml new file mode 100644 index 0000000..13704c3 --- /dev/null +++ b/tamma.yaml @@ -0,0 +1,7 @@ +# TODO: Somehow auto-generate this via Nix? Since all the hosts are defined there. + +hosts: + - name: alderaan + ip: alderaan + data: + user: root -- 2.44.1