From a40f78e88fbd1fb42e868e84f5411d0c5fe89c57 Mon Sep 17 00:00:00 2001 From: cswimr Date: Wed, 20 Nov 2024 12:27:59 -0500 Subject: [PATCH] chore(repo): use `nixpkgs-python` to get python version instead of setting `languages.python.package` --- flake.lock | 38 ++++++++++++++++++++++++++++++++++++++ flake.nix | 4 +++- 2 files changed, 41 insertions(+), 1 deletion(-) diff --git a/flake.lock b/flake.lock index a0a5c22..5de0f7a 100644 --- a/flake.lock +++ b/flake.lock @@ -68,6 +68,22 @@ "type": "github" } }, + "flake-compat_2": { + "flake": false, + "locked": { + "lastModified": 1696426674, + "narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=", + "owner": "edolstra", + "repo": "flake-compat", + "rev": "0f9255e01c2351cc7d116c072cb317785dd33b33", + "type": "github" + }, + "original": { + "owner": "edolstra", + "repo": "flake-compat", + "type": "github" + } + }, "flake-parts": { "inputs": { "nixpkgs-lib": [ @@ -205,6 +221,27 @@ "type": "github" } }, + "nixpkgs-python": { + "inputs": { + "flake-compat": "flake-compat_2", + "nixpkgs": [ + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1730716553, + "narHash": "sha256-n4cibCp/ggDlSacCTnP8dVnywclQKYcHy6PRfe35Hk0=", + "owner": "cachix", + "repo": "nixpkgs-python", + "rev": "8fcdb8ec34a1c2bae3f5326873a41b310e948ccc", + "type": "github" + }, + "original": { + "owner": "cachix", + "repo": "nixpkgs-python", + "type": "github" + } + }, "nixpkgs_2": { "locked": { "lastModified": 1717432640, @@ -241,6 +278,7 @@ "inputs": { "devenv": "devenv", "nixpkgs": "nixpkgs_3", + "nixpkgs-python": "nixpkgs-python", "systems": "systems" } }, diff --git a/flake.nix b/flake.nix index 3ec26c4..f0ed09f 100644 --- a/flake.nix +++ b/flake.nix @@ -1,6 +1,8 @@ { inputs = { nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable"; + nixpkgs-python.url = "github:cachix/nixpkgs-python"; + nixpkgs-python.inputs = { nixpkgs.follows = "nixpkgs"; }; systems.url = "github:nix-systems/default"; devenv.url = "github:cachix/devenv"; devenv.inputs.nixpkgs.follows = "nixpkgs"; @@ -33,7 +35,7 @@ { languages.python = { enable = true; - package = pkgs.python311; + version = "3.11"; uv = { enable = true; sync = {