# Fix workspace removal, and chase down all the ramifications \(\#53366\) · gitcafe/zed

[View on GitCafe](https://git.cafe/gitcafe/zed/commit/6286b7c5fbd56489f7f81b071516a204df51b22f)

Repository: [gitcafe/zed](https://git.cafe/gitcafe/zed)

Visibility: public

Requested revision: 6286b7c5fbd56489f7f81b071516a204df51b22f

Requested commit: 6286b7c5fbd56489f7f81b071516a204df51b22f

Commit: 6286b7c5fbd56489f7f81b071516a204df51b22f

Tree: 3b94b4debbaa31515d8332cca2747a27e5cdf55a

Author: Mikayla Maki

Committer: GitHub

## Message

```
Fix workspace removal, and chase down all the ramifications (#53366)

This PR adjusts how project group removal works in the sidebar to be
project group aware. Removal is now a batched operation, and supports a
contextually appropriate fallback active workspace fallback. In the
process of removing this, I had to chase down and fix other broken code:
- Removes the "move to new window" actions
- Changed the sidebar to store things in "most recently added" order
- The recent project UI was still using workspaces, instead of project
groups
- Adjusted the archive command to use the new APIs to remove the
workspace associated with that worktree (cc: @rtfeldman)
- The property tests where still using indexes and workspaces instead of
project groups

Self-Review Checklist:

- [ ] I've reviewed my own diff for quality, security, and reliability
- [x] Unsafe blocks (if any) have justifying comments
- [x] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [x] Tests cover the new/changed behavior
- [x] Performance impact has been considered and is acceptable

Closes #ISSUE

Release Notes:

- N/A
```

## Parents

- [a2cf71d09e653012cf51cba78f640d3c0d6d75d4](https://git.cafe/gitcafe/zed/commit/a2cf71d09e653012cf51cba78f640d3c0d6d75d4?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zed/tree/6286b7c5fbd56489f7f81b071516a204df51b22f?format=markdown)
