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

auto-indentation issue: extra tabs for some reason (unable to reproduce) #3358

Closed
adsick opened this issue Aug 8, 2022 · 2 comments
Closed
Labels
C-bug Category: This is a bug

Comments

@adsick
Copy link

adsick commented Aug 8, 2022

Summary

for some reason additional tabs appear when I consequently pushed enter in insert mode. See video to understand.

Reproduction Steps

I tried this:

  1. hx

  2. edited a rust document
    3. tried 'C', it added a cursor, damn sux...

  3. 'x' to select current line

  4. 'c' to edit it

  5. it deleted newline character and I am on the start of the next line with code not enjoying it

  6. I do some manual indentation

  7. I push enter a few times and see it adds one more ident for every enter press.
    Screencast from 08-08-22 21:43:09.webm

I expected this to happen:
constant indentation
Instead, this happened:
arithmetically growing indentation

Helix log

No response

Platform

Linux

Terminal Emulator

alacritty

Helix Version

helix 22.05 (bf6f704)

@adsick adsick added the C-bug Category: This is a bug label Aug 8, 2022
@the-mikedavis
Copy link
Member

I can reproduce this if I remove Rust's indents query file runtime/queries/rust/indents.scm and edit inside a similar struct. That was added back in #1562: you need to copy the runtime/ directory from the repo to your ~/.confix/helix/runtime or ideally use a symlink. hx --health rust should give a checkmark for "Indent queries".

tried 'C', it added a cursor, damn sux...
...
it deleted newline character and I am on the start of the next line with code not enjoying it

This isn't productive to the discussion. Please refrain from snippy commentary in the future.

Also, being a vim clone is explicity out of scope for this project. If you prefer vim's behavior, please just use vim.

@adsick
Copy link
Author

adsick commented Aug 9, 2022

thanks for the respond

Also, being a vim clone is explicity out of scope for this project.

I know that, but I am sure that 'change current line' functionality is far more common than using multicursor. I bet a lot people never use multiple cursors.

and no there is no need to get very opinionated because after all the best we can do is to give users the ability to customize keybinding to fit whatever style they want.

Please refrain from snippy commentary in the future.

sorry for that

If you prefer vim's behavior, please just use vim.

I just complaned about single keybinding

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Category: This is a bug
Projects
None yet
Development

No branches or pull requests

2 participants