Something went wrong. Try again.
karitham.dev website! atproto & fancy ssg + csr & blog articles karitham.dev
atproto gleam blog nix
Something went wrong. Try again.
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273{ inputs = { nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable"; }; outputs = { nixpkgs, ... }: let forEachSupportedSystem = f: nixpkgs.lib.genAttrs [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ] ( system: f { pkgs = import nixpkgs { inherit system; }; } );
formatters = { pkgs }: [ pkgs.gleam pkgs.nixfmt pkgs.rustfmt pkgs.taplo pkgs.shfmt pkgs.nufmt pkgs.prettier ]; in { formatter = forEachSupportedSystem ( { pkgs }: pkgs.writeShellScriptBin "treefmt-wrapped" '' export PATH="${ pkgs.lib.makeBinPath (formatters { inherit pkgs; }) }:$PATH" exec ${pkgs.treefmt}/bin/treefmt "$@" '' );
packages = forEachSupportedSystem ( { pkgs }: { parse-plays = pkgs.rustPlatform.buildRustPackage { pname = "parse-plays"; version = "0.1.0"; src = ./tools/parse-plays; cargoLock.lockFile = ./tools/parse-plays/Cargo.lock; }; } );
devShells = forEachSupportedSystem ( { pkgs }: { default = pkgs.mkShell { packages = with pkgs; [ gleam beamMinimal28Packages.erlang beamMinimal28Packages.rebar3 treefmt just nodejs
rustc cargo clippy cargo-edit rust-analyzer ] ++ (formatters { inherit pkgs; }); }; } ); };}