Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .envrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#use_flake_if_supported
use flake
# eval "$shellHook"
130 changes: 130 additions & 0 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

49 changes: 49 additions & 0 deletions flake.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
{
description = "Risinglight";

inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
rust-overlay.url = "github:oxalica/rust-overlay";
flake-utils.url = "github:numtide/flake-utils";
};

outputs = { nixpkgs, flake-utils, rust-overlay,... }: let
lib = {
inherit (flake-utils.lib) defaultSystems eachSystem;
};
supportedSystems = [ "x86_64-linux" ];
in lib.eachSystem supportedSystems (system: let

pkgs = import nixpkgs {
inherit system;
overlays = [
(import rust-overlay)
];
};
pinnedRust = (pkgs.rust-bin.fromRustupToolchainFile ./rust-toolchain).override {
extensions = ["rustc-dev" "rust-src" "rust-analyzer-preview" ];
targets = [ "x86_64-unknown-linux-gnu" ];
};
rustPlatform = pkgs.makeRustPlatform {
rustc = pinnedRust;
cargo = pinnedRust;
};
in {

devShell = pkgs.mkShell {
hardeningDisable = [
"fortify"
];
nativeBuildInputs = [
pinnedRust
pkgs.protobuf
];
buildInputs = [
];

shellHook = ''
'';
};

});
}