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 24, 2023
1 parent 7f59216 commit 1aa6ea8
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 1aa6ea8

Please sign in to comment.