open-goverance/flake.nix

46 lines
1,023 B
Nix
Raw Normal View History

{
description = "UL Computer Society Open Governance";
inputs = {
nixpkgs.url = "nixpkgs/nixos-unstable";
utils.url = "github:numtide/flake-utils";
bfom.url = "gitlab:silver_rust/bfom";
};
outputs = { self, nixpkgs, utils, bfom }: utils.lib.eachDefaultSystem (system:
let
pkgs = import nixpkgs {
system = "${system}";
config = {
allowUnfree = true;
permittedInsecurePackages = [
"electron-25.9.0"
];
};
};
in rec {
# `nix develop`
devShell = pkgs.mkShell {
nativeBuildInputs = with pkgs; [ obsidian ];
shellHook = ''
${pkgs.obsidian}/bin/obsidian &
BG_PID=$!
trap "kill -9 $BG_PID" EXIT
'';
};
apps.bfom = {
type = "app";
program = "${bfom.defaultPackage.x86_64-linux}/bin/cargo-bfom";
};
packages.handovers = pkgs.writeShellScriptBin "format_handovers" ''
cd Committee
${bfom.defaultPackage.x86_64-linux}/bin/cargo-bfom
'';
});
}