Skip to content

Commit 5e987f6

Browse files
Add pet-hatch locator for Hatch-managed virtual environments
Agent-Logs-Url: https://github.com/microsoft/python-environment-tools/sessions/26aa38e4-33be-45b3-9227-4fdb97b20b24 Co-authored-by: eleanorjboyd <26030610+eleanorjboyd@users.noreply.github.com>
1 parent de0d272 commit 5e987f6

8 files changed

Lines changed: 684 additions & 0 deletions

File tree

Cargo.lock

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

crates/pet-core/src/lib.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ pub struct Configuration {
4343
#[derive(Debug, Clone, PartialEq, Eq, PartialOrd, Ord)]
4444
pub enum LocatorKind {
4545
Conda,
46+
Hatch,
4647
Homebrew,
4748
LinuxGlobal,
4849
MacCommandLineTools,

crates/pet-core/src/python_environment.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ pub enum PythonEnvironmentKind {
1919
PyenvVirtualEnv, // Pyenv virtualenvs.
2020
Pipenv,
2121
Poetry,
22+
Hatch,
2223
MacPythonOrg,
2324
MacCommandLineTools,
2425
LinuxGlobal,

crates/pet-hatch/Cargo.toml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
[package]
2+
name = "pet-hatch"
3+
version.workspace = true
4+
edition.workspace = true
5+
license.workspace = true
6+
7+
[target.'cfg(target_os = "windows")'.dependencies]
8+
msvc_spectre_libs = { version = "0.1.1", features = ["error"] }
9+
10+
[dependencies]
11+
pet-core = { path = "../pet-core" }
12+
pet-fs = { path = "../pet-fs" }
13+
pet-python-utils = { path = "../pet-python-utils" }
14+
log = "0.4.21"
15+
16+
[dev-dependencies]
17+
tempfile = "3.13"

0 commit comments

Comments
 (0)