sleistner / vscode-fileutils

Visual Studio Code Extension
https://marketplace.visualstudio.com/items?itemName=sleistner.vscode-fileutils
MIT License
190 stars 26 forks source link

Unable to delete file on Ubuntu #633

Open As1fAli opened 1 year ago

As1fAli commented 1 year ago

Describe the bug Maybe due to permissions issue, I cannot delete file on Ubuntu Linux.

To Reproduce

  1. Open a file in VS Code you want to delete.
  2. Open command prompt using ctrl+shift+p
  3. Click on 'File Utils: Delete'

Screenshots image

Desktop (please complete the following information):

hsfzxjy commented 1 year ago

This problem may be caused by that the file to delete is not on the same mount point as your $HOME.

I resolve this by starting vscode with envvar ELECTRON_TRASH=kioclient5. Full list of options are:

As1fAli commented 1 year ago

This problem may be caused by that the file to delete is not on the same mount point as your $HOME.

I resolve this by starting vscode with envvar ELECTRON_TRASH=kioclient5. Full list of options are:

  • kioclient5
  • kioclient
  • trash-cli (sudo apt install trash-cli)
  • gvfs-trash

Can you please send here the command to run vscode with envvar set?

hsfzxjy commented 1 year ago

Make sure:

  1. Command kioclient5 is available
  2. All vscode instances are shut down. You may verify via ps aux | grep code

Then run ELECTRON_TRASH=kioclient5 code /path/to/your/workspace

As1fAli commented 1 year ago

Make sure:

  1. Command kioclient5 is available
  2. All vscode instances are shut down. You may verify via ps aux | grep code

Then run ELECTRON_TRASH=kioclient5 code /path/to/your/workspace

Okay Thanks, I will try.

hsfzxjy commented 1 year ago

You may replace "kioclient5" with other values listed above, as things could vary on different machines.