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

Freeze when I try to active some options #31

Open
t1gu1 opened this issue Aug 1, 2023 · 6 comments
Open

Freeze when I try to active some options #31

t1gu1 opened this issue Aug 1, 2023 · 6 comments

Comments

@t1gu1
Copy link

t1gu1 commented Aug 1, 2023

When I try to active dir ou files my terminal freeze.
I have to close and reopen everything.

image

Other option seems toggle correctly.

Is there some prerequisite package to install in the OS to get it works?

@t1gu1
Copy link
Author

t1gu1 commented Aug 1, 2023

It seems to happend only if I wrote a patterns or replacement before I toggle the dir or files option.

image

@t1gu1
Copy link
Author

t1gu1 commented Aug 1, 2023

Oh, directly when I active dir option and I write something in the patterns, it freeze too.

@t1gu1
Copy link
Author

t1gu1 commented Aug 1, 2023

I finally find why.

My project is too "big" and it search everywhere.
I simply change the files argument to: src/**/* and it was ok.

Is there a way to exclude files?
Like /ios/Pods/,/vendor/bundle/,.history,node_modules,dist,.git,build/

@AckslD
Copy link
Owner

AckslD commented Aug 1, 2023

Hi @t1gu1, if you're doing recursive replacements in a directory it can be useful to disable preview while typing the replacements and setting the options since that will do the replacements for each keystroke.

@AckslD
Copy link
Owner

AckslD commented Aug 1, 2023

Regarding your question to exclude files, currently muren calls out to :vimgrep but maybe we can optionally instead call :grep which the user can configure to use rg or anything and custom configs to ignore eg .gitignore.

But the syntax for patterns for both the search-term and files would then potentially have to be different.

@t1gu1
Copy link
Author

t1gu1 commented Aug 2, 2023

Considering the .gitignore file would be a nice enhancement.
I would'nt had any issues with that.



Some Ideas


Maybe it could be an idea to remove de default value of the files options.

  • When there is nothing, it will list all the files except the one in the .gitignore with that command git ls-files.
  • If the git ls-files list nothing, it will default to the */**

You can try it with a: vimgrep thingsToSearch `git ls-files` | cw


Maybe add a call to action to make the search?
e.g. when you pass from insert mode to normal mode it call the search.

In the options, it could have a live preview option instead of a preview and the preview could be always on with the call action.

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

No branches or pull requests

2 participants