Skip to content

Commit 629df58

Browse files
committed
flake: migrate to flake with numtide/blueprint
1 parent 2bed792 commit 629df58

File tree

4 files changed

+109
-10
lines changed

4 files changed

+109
-10
lines changed

.envrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
use nix
1+
use flake

flake.lock

Lines changed: 85 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

flake.nix

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
{
2+
description = "Simple flake with a devshell";
3+
4+
# Add all your dependencies here
5+
inputs = {
6+
nixpkgs.url = "github:NixOS/nixpkgs?ref=nixos-unstable";
7+
blueprint.url = "github:numtide/blueprint";
8+
blueprint.inputs.nixpkgs.follows = "nixpkgs";
9+
rust-overlay.url = "github:oxalica/rust-overlay";
10+
rust-overlay.inputs.nixpkgs.follows = "nixpkgs";
11+
};
12+
13+
# Load the blueprint
14+
outputs = inputs:
15+
inputs.blueprint {
16+
inherit inputs;
17+
prefix = "nix/";
18+
nixpkgs.overlays = [
19+
inputs.rust-overlay.overlays.default
20+
];
21+
};
22+
}

shell.nix renamed to nix/devshell.nix

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,4 @@
1-
{
2-
pkgs ?
3-
import <nixpkgs> {
4-
overlays = [
5-
rust-overlay.overlays.default
6-
];
7-
},
8-
rust-overlay ? builtins.getFlake "github:oxalica/rust-overlay",
9-
}: let
1+
{pkgs}: let
102
rustToolchain = pkgs.rust-bin.stable.latest.default.override {
113
extensions = ["rust-src"];
124
};

0 commit comments

Comments
 (0)