Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: extra char when vim option 'selection' = exclusive #88

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

adoyle-h
Copy link

@adoyle-h adoyle-h commented Sep 2, 2024

Description

When :set selection=exclusive, the returned value from get_visual() will contain an extra char.

Use vim.fn.getregion which follows vim option 'selection' to fix this issue.

Type of change

  • Bug fix (non-breaking change which fixes an issue)

Configuration:

  • Neovim version (nvim --version): v0.10.1
  • Operating system and version: Darwin Kernel Version 23.6.0

Checklist:

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

When `:set selection=exclusive`, the returned value from `get_visual()` will contain an  extra char.

Use `vim.fn.getregion` which follows vim option 'selection' to fix this issue.
@adoyle-h
Copy link
Author

adoyle-h commented Sep 9, 2024

@weeman1337 Can you review this PR? Thanks

adoyle-h added a commit to adoyle-h/one.nvim that referenced this pull request Oct 3, 2024
instead of nvim-telescope/telescope-live-grep-args.nvim

Waiting the PR to be merged: nvim-telescope/telescope-live-grep-args.nvim#88
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.

1 participant