Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add huak-workspace #817

Merged
merged 1 commit into from
Nov 7, 2023
Merged

Add huak-workspace #817

merged 1 commit into from
Nov 7, 2023

Conversation

cnpryer
Copy link
Owner

@cnpryer cnpryer commented Nov 6, 2023

cc #791

The goal is to simplify Workspaces. Often I need the following for different reasons:

// dir (root)
// └── project (child)
// | └── pyproject.toml
// └── pyproject.toml
let dir = TempDir::new().unwrap();
let mock = create_mock_ws(dir.as_ref());
let cwd = mock.join("package");
let ws = resolve_root(cwd, PathMarker::file("pyproject.toml"));

assert!(ws.root().exists());
assert_eq!(ws.root(), dir.path());

Reasons:

  1. toolchain - The toolchain management system has a concept of scopes which tie workspaces to toolchains.
  2. virtual environment - Resolving virtual environments for projects often requires resolving a workspace.
  3. package management - Resolving packages requires resolving workspaces.

I'd like to have a common resolver since many things will require it.

@cnpryer cnpryer force-pushed the workspace branch 30 times, most recently from 52b2bd8 to 420650b Compare November 7, 2023 02:42
@cnpryer cnpryer marked this pull request as ready for review November 7, 2023 02:46
@cnpryer cnpryer mentioned this pull request Nov 7, 2023
@cnpryer cnpryer merged commit a15fd58 into master Nov 7, 2023
@cnpryer cnpryer deleted the workspace branch November 7, 2023 02:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant