Skip to content

Commit

Permalink
Add maturin, update nixos distribution
Browse files Browse the repository at this point in the history
  • Loading branch information
alecandido committed Oct 12, 2023
1 parent 272208e commit 1918434
Show file tree
Hide file tree
Showing 2 changed files with 40 additions and 35 deletions.
8 changes: 4 additions & 4 deletions flake.lock

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

67 changes: 36 additions & 31 deletions flake.nix
Original file line number Diff line number Diff line change
@@ -1,45 +1,50 @@
{
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-22.11";
nixpkgs.url = "github:NixOS/nixpkgs/nixos-23.05";
systems.url = "github:nix-systems/default";
devenv.url = "github:cachix/devenv";
nixpkgs-python.url = "github:cachix/nixpkgs-python";
fenix.url = "github:nix-community/fenix";
fenix.inputs.nixpkgs.follows = "nixpkgs";
};

outputs = {
self,
nixpkgs,
devenv,
systems,
...
} @ inputs: let
forEachSystem = nixpkgs.lib.genAttrs (import systems);
in {
devShells =
forEachSystem
(system: let
pkgs = nixpkgs.legacyPackages.${system};
in {
default = devenv.lib.mkShell {
inherit inputs pkgs;
modules = [
{
packages = with pkgs; [maturin];

languages.python = {
enable = true;
venv.enable = true;
version = "3.11";
};
languages.rust = {
enable = true;
channel = "stable";
};
}
];
};
});
};

nixConfig = {
extra-trusted-public-keys = "devenv.cachix.org-1:w1cLUi8dv3hnoSPGAuibQv+f9TZLr6cv/Hm9XgU50cw=";
extra-substituters = "https://devenv.cachix.org";
};

outputs = { self, nixpkgs, devenv, systems, ... } @ inputs:
let
forEachSystem = nixpkgs.lib.genAttrs (import systems);
in
{
devShells = forEachSystem
(system:
let
pkgs = nixpkgs.legacyPackages.${system};
in
{
default = devenv.lib.mkShell {
inherit inputs pkgs;
modules = [
{
languages.python = {
enable = true;
venv.enable = true;
version = "3.11";
};
languages.rust = {
enable = true;
channel = "stable";
};
}
];
};
});
};
}

0 comments on commit 1918434

Please sign in to comment.