telescope.nvim icon indicating copy to clipboard operation
telescope.nvim copied to clipboard

WIP fix escapeing windows special chars

Open davisthedev opened this issue 2 years ago • 5 comments

Description

Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context

Fixes #2446

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list relevant details about your configuration

  • [x] Tested on windows by navigating Telescope pickers and opening files to ensure special characters were escaped.

Configuration:

  • Neovim version (nvim --version): 0.9.1
  • Operating system and version: Windows 11

Checklist:

  • [x] My code follows the style guidelines of this project (stylua)
  • [x] I have performed a self-review of my own code
  • [x] I have commented my code, particularly in hard-to-understand areas
  • [ ] I have made corresponding changes to the documentation (lua annotations)

davisthedev avatar Aug 15 '23 13:08 davisthedev

@Conni2461 I'm thinking some of this probably belongs in plenary.path.

@davisthedev I'm also curious if using :set shellslash helps in any way in telescope.

jamestrew avatar Aug 15 '23 21:08 jamestrew

@jamestrew I did try :set shellslash before I started any dev work. It did not make a difference for telescope.

I would be happy to add this to plenary if that would help? I am super new to lua and the neovim ecosystem so I may have some questions.

davisthedev avatar Aug 15 '23 21:08 davisthedev

Semi-related issue with plenary not gracefully handling windows paths set shellslash https://github.com/nvim-telescope/telescope.nvim/issues/2651

jamestrew avatar Aug 16 '23 23:08 jamestrew

i think we should do that in plenary. And we already had a discussion about this in plenary

https://github.com/nvim-lua/plenary.nvim/issues/254 https://github.com/nvim-lua/plenary.nvim/pull/371

Conni2461 avatar Sep 10 '23 10:09 Conni2461

The shellslash stuff looks very hairy to fix. I don't think I have the capacity/patience to fix it especially with this being a cross-platform/windows issue and I don't easily have a windows environment to test this kind of stuff.

And I believer when we're looking to eventually deprecate plenary and possibly rely more on neovim core of path stuff.

jamestrew avatar Sep 13 '23 00:09 jamestrew