ow-mod-man/flake.nix
Ben C 4a3e1eaa50
[CHORE] Update Deps, Switch to flakelight
- The Nix flake now uses flakelight
- The dev shell uses latest Rust version to be compatible
  with GH actions version
- Ran the newest clippy, fixing all new lints
- Ran a tree-wide nix fmt
2025-07-10 02:21:03 -04:00

38 lines
1.0 KiB
Nix

{
description = "Flake for owmods-cli and owmods-gui";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
flakelight.url = "github:nix-community/flakelight";
rust-overlay = {
url = "github:oxalica/rust-overlay";
inputs.nixpkgs.follows = "nixpkgs";
};
};
outputs = {flakelight, ...} @ inputs:
flakelight ./. {
inherit inputs;
withOverlays = [inputs.rust-overlay.overlays.default];
flakelight.builtinFormatters = false;
formatters = pkgs: let
prettier = "${pkgs.prettier}/bin/prettier --write .";
alejandra = "${pkgs.alejandra}/bin/alejandra .";
rustfmt = "${pkgs.rustfmt}/bin/rustfmt";
just = "${pkgs.just}/bin/just --fmt --unstable";
in {
"justfile" = just;
"*.nix" = alejandra;
"*.js" = prettier;
"*.ts" = prettier;
"*.jsx" = prettier;
"*.tsx" = prettier;
"*.md" = prettier;
"*.json" = prettier;
"*.rs" = rustfmt;
};
};
}