Go to file
Stranger Bot 84910e3cec
Update flake/dependencies
2023-09-04 04:09:05 -04:00
sources Update flake/dependencies 2023-09-01 04:02:43 -04:00
test-crate Add a test crate 2023-05-13 15:51:23 -04:00
.gitignore feat: Add samply to devShell 2023-06-08 21:30:22 -04:00
LICENSE Add license file 2023-05-13 14:11:48 -04:00
README.md Add readme 2023-05-13 16:15:15 -04:00
flake.lock Update flake/dependencies 2023-09-04 04:09:05 -04:00
flake.nix fix: Fix dylib names on darwin 2023-07-21 23:07:44 -04:00
update.sh Add updater script 2023-05-13 15:59:18 -04:00

README.md

Nix Flakes Rust Helper

A helper flake for automatically generating flake contents for rust projects, including building, testing, documenting, auditing, and linting of rust projects, as well as other useful toolchain packages

Provided toolchain

DevShell

The provided devShell includes the following rust specific packages, in addition to the usual rust toolchain (including rust-analyzer):

These general workflow utilities are provided:

Dependencies

The following dependencies are provided by default:

  • cmake
  • openssl
  • pkg-config

Usage

Repository with a single crate (not a workspace)

Create a flake.nix in the root of the repository with the following contents:

{
  inputs = { rust = { url = "git+https://git.stranger.systems/nix/Rust"; }; };
  description = "Simple Test Package";

  outputs = { self, nixpkgs, rust }:
    rust.single {
      crateName = "CRATE_NAME";
      src = ./.;
    };
}

Optionally create a .envrc in the root of the repository with the following contents:

use flake