zed icon indicating copy to clipboard operation
zed copied to clipboard

Can delete unaccessible private files from tree view

Open fdionisi opened this issue 2 years ago • 0 comments

Check for existing issues

  • [X] Completed

Describe the bug / provide steps to reproduce it

A guest in a collaborative session can delete private files from the tree view even though they are inaccessible.

Steps to reproduce:

  1. With default settings, the host set up a project containing .env.
  2. Guest join the collaborative session.
  3. Guest left-click on the .env file: file is inaccessible.
  4. Guest right-click on the .env file and "Delete" from the context menu.
  5. 💥 Private file gets deleted.

Environment

Zed: v0.124.6 (Zed Preview) OS: macOS 14.2.1 Memory: 16 GiB Architecture: aarch64

If applicable, add mockups / screenshots to help explain present your vision of the feature

I'd expect either:

  • Private files are invisible (i.e., not loaded in the file tree) It's not my favourite, as it may introduce magic.
  • Context menu shows no available action. Perhaps a bit sterile and gives an "incomplete feature" feeling.
  • Custom context menu/tooltip prompting the restriction. Explicit and transparent, probably my favourite, but it introduces multiple behaviours on a single element.

If applicable, attach your ~/Library/Logs/Zed/Zed.log file to this issue.

If you only need the most recent lines, you can run the zed: open log command palette action to see the last 1000.

No response

fdionisi avatar Feb 28 '24 09:02 fdionisi