Skip to content

cli: show workspace roots in workspace list#9826

Open
joshka wants to merge 1 commit into
jj-vcs:mainfrom
joshka:joshka/workspace-list-default-root
Open

cli: show workspace roots in workspace list#9826
joshka wants to merge 1 commit into
jj-vcs:mainfrom
joshka:joshka/workspace-list-default-root

Conversation

@joshka

@joshka joshka commented Jul 18, 2026

Copy link
Copy Markdown
Contributor

Follow-up to #9713. This makes the root-bearing workspace list output the default and removes the now-redundant builtin_workspace_list_with_root alias.

Fixes #7114.

Checklist

If applicable:

  • I have updated CHANGELOG.md
  • I have updated the documentation (README.md, docs/, demos/)
  • I have updated the config schema (cli/src/config-schema.json)
  • I have added/updated tests to cover my changes
  • I fully understand the code that I am submitting (what it does,
    how it works, how it is organized), including any code drafted by an LLM.
  • For any prose generated by an LLM, I have proof-read and copy-edited with
    an eye towards deleting anything that is irrelevant, clarifying anything
    that is confusing, and adding details that are relevant. This includes,
    for example, commit descriptions, PR descriptions, and code comments.

@joshka
joshka requested a review from a team as a code owner July 18, 2026 02:10
@joshka
joshka force-pushed the joshka/workspace-list-default-root branch from ae85451 to 1f7e335 Compare July 18, 2026 02:15
@martinvonz

Copy link
Copy Markdown
Contributor

FYI @josephlou5, @yuja, and @pksunkara since you reviewed the original PR. I think this is a good idea. I haven't looked at the implementation yet.

Comment thread docs/config.md Outdated
@pksunkara

Copy link
Copy Markdown
Member

What's the rationale for this change? Is there any discussion?

@pksunkara

pksunkara commented Jul 18, 2026

Copy link
Copy Markdown
Member

Linkin the discussion here

I don't mind this being the default

@martinvonz

Copy link
Copy Markdown
Contributor

There's a little bit of discussion on Discord. The rationale is just that it seems like you would generally want to see the path, and you can pass a different template if you don't want it. Do you think it's a bad idea? I can see it being annoying for people who have the workspaces "far away" from each other so the relative path is long.

@joshka

joshka commented Jul 18, 2026

Copy link
Copy Markdown
Contributor Author

The original PR I thought about wanting this to be the default, but went with the conservative approach rather than what I felt was the correct approach for most uses.

@alexandre-hallaine

Copy link
Copy Markdown

I've pushed a fix for the Windows test failures to my fork. You can fetch/cherry-pick it from here:
alexandre-hallaine@55c1e89

@joshka
joshka force-pushed the joshka/workspace-list-default-root branch 2 times, most recently from ecda826 to 600c908 Compare July 19, 2026 12:28
@joshka
joshka added this pull request to the merge queue Jul 19, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to a conflict with the base branch Jul 19, 2026
@martinvonz

Copy link
Copy Markdown
Contributor

This needs to be rebased

Include each recorded workspace root in the default `jj workspace list`
template instead of requiring users to opt in with a separate builtin
template.

The workspace path is generally useful when users have multiple workspaces
and need to find the checkout on disk. Keeping this in the default output
also avoids requiring users to know the template language just to answer
that common question.

Drop `builtin_workspace_list_with_root` now that `builtin_workspace_list`
has the root-bearing output. Workspaces whose roots are not recorded or
cannot be resolved are still listed without a path.

Fixes jj-vcs#7114.
@joshka
joshka force-pushed the joshka/workspace-list-default-root branch from 600c908 to 551c3a0 Compare July 20, 2026 00:52
@joshka
joshka enabled auto-merge July 20, 2026 01:04
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.

FR: Allow workspace path in workspace_list template

4 participants