yorokobot/flake.nix

59 lines
1.4 KiB
Nix
Raw Normal View History

2022-09-22 05:10:56 +02:00
{
description = "Discord Bot managing users interests.";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
rust-overlay.url = "github:oxalica/rust-overlay";
flake-utils.url = "github:numtide/flake-utils";
};
outputs = {self, nixpkgs, rust-overlay, flake-utils, ...}:
flake-utils.lib.eachDefaultSystem (system:
let
overlays = [ (import rust-overlay) ];
pkgs = import nixpkgs {
inherit system overlays;
};
in
with pkgs;
{
2023-04-23 16:27:53 +02:00
packages.default = pkgs.rustPlatform.buildRustPackage rec {
pname = "yorokobot";
version = "0.1.0";
src = self;
cargoSha256 = "sha256-iPHtsaIXw1WdyFZPaTlbwhBF35PvM/oM6jCxxeQ1+58=";
meta = with pkgs.lib; {
description = "Discord bot implementing a topic management system";
homepage = "https://sr.ht/~dala/yorokobot";
license = licenses.agpl3;
};
};
2022-09-22 05:10:56 +02:00
devShells.default = mkShell {
buildInputs = [
(
rust-bin.stable.latest.default.override {
extensions = [ "rust-src" ];
}
)
];
packages = with pkgs; [
rust-analyzer
rustfmt
2022-11-19 05:45:38 +01:00
gdb
2022-09-22 05:10:56 +02:00
];
2022-10-17 06:12:54 +02:00
shellHook = ''
set -a
source .env
set +a
'';
2022-09-22 05:10:56 +02:00
};
}
);
}