feat: setup base

This commit is contained in:
tux
2026-05-06 00:55:41 +05:30
parent a62346367f
commit 33408ed45e
35 changed files with 1730 additions and 0 deletions

View File

@@ -0,0 +1,4 @@
{ inputs, ... }:
{
imports = [ inputs.flake-parts.flakeModules.modules ];
}

View File

@@ -0,0 +1,28 @@
{
inputs,
withSystem,
...
}:
{
flake.overlays = {
modifications = final: prev: {
tnvim = inputs.tnvim.packages.${prev.stdenv.hostPlatform.system}.default;
};
stable-packages = final: _prev: {
stable = import inputs.nixpkgs-stable {
system = final.stdenv.hostPlatform.system;
config.allowUnfree = true;
};
};
};
perSystem =
{ system, ... }:
{
_module.args.pkgs = import inputs.nixpkgs {
inherit system;
overlays = builtins.attrValues inputs.self.overlays;
};
};
}

View File

@@ -0,0 +1,6 @@
{
systems = [
"x86_64-linux"
"aarch64-linux"
];
}

23
modules/flake/treefmt.nix Normal file
View File

@@ -0,0 +1,23 @@
{ inputs, ... }:
{
imports = [
inputs.treefmt-nix.flakeModule
];
perSystem =
{
config,
pkgs,
system,
...
}:
{
treefmt.config = {
projectRootFile = "flake.nix";
flakeCheck = true;
programs = {
nixfmt.enable = true;
};
};
};
}