-
Notifications
You must be signed in to change notification settings - Fork 3
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
Expansion of ~ on Windows #7
Comments
This works fine for me. Emacs already expands Urgrep isn't doing anything special with the
|
I use project.el to open the project and files. I use ripgrep to search for pattern and it is not working. The project stores the path of project in .emacs.d/projects file as "~/Repo" etc. That could be the problem. This problem is not seen if I am using consult-ripgrep. This can be reproduced with ugrep also. |
The actual value of I believe the issue you're seeing is this: BurntSushi/ripgrep#951. I guess that means that Urgrep needs a special-case for ripgrep to always include a directory as an explicit command argument, else it will hang waiting for stdin that never arrives (but only on Windows, since Emacs can't use PTYs to communicate with child processes there). |
This was broken because ripgrep/ugrep assume you're piping data in to search if stdin is a pipe. Since Emacs only uses pipes for child processes on Windows, things get confused. The solution is to always pass the search directory to ripgrep/ugrep, even when it's just ".".
@elge70 Could you try this branch to see if things work? https://github.com/jimporter/urgrep/tree/ripgrep-windows |
If the project is under HOME directory on windows (where HOME env variable has been defined), none of the grep utilities works correctly. But it works correctly under linux. Probably we may have to use (expand-file-name) to get the absolute path of the directory
The text was updated successfully, but these errors were encountered: