Git Product home page Git Product logo

qgrep's People

Contributors

asakovets avatar beastle9end avatar ch45er avatar data-man avatar freaky avatar g0xa52a2a avatar ip-gpu avatar ivzhh avatar katharina-r avatar mrwitek avatar nightra avatar rivten avatar shachaf avatar swardle avatar vegorov-rbx avatar wegank avatar zeux avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

qgrep's Issues

multiline search

perhaps something obvious for others..., but really would be nice to have an example of multi-line search. not sure whether is feature request or docs improvement request.

otherwise all works great on Win10 20H2 with Windows Terminal and PS 7.2

update

what i understand from https://zeux.io/2019/04/20/qgrep-internals/ is that qgrep works on a line-by-line basis, but then the article states that ...

The search is done on a line by line basis, however instead of feeding each line to the regular expression engine at a time, the regular expression is ran on the entire file at a time

which means that there should be an option to apply an s or sm modifier to the regexp (re2 supports these, although I tried to feed (?sm) to qgrep and error is produced).

... so the issue is rather a feature request.

[FIXED] Windows binary

Dear Arseny,
Could you be so kind to generate .exe for the rest of us who are merely users w/o compiler?

qgrep doesn't work on XFS filesystem

It fails to iterate through sub-directories. The problem is in fileutil_posix.cpp:44. You are depending on the d_type field returned by readdir() to determine what is a directory. If you you check the readdir man page you'll see that this field is optional and not supported by all systems; it turns out that XFS on Linux doesn't provide this information.

qgrep search results displays files with paths containing backslashes in Linux (instead of slashes)

Summary:
I am using qgrep (build be me from sources on github) on Linux CentOS, and in the search results I see back-slashes instead of slashes in file paths (those files where the matches occur)

Test steps:
root@DevMachine:/opt/devenv/projects# qgrep search tos Vl "xsl.cgi"
\opt\devenv\project\build.shinobi(465): "xsl.cgi":{"files":"cgi/xsl/.cc",
\opt\devenv\project\build.shinobi.old(453): "xsl.cgi":{"files":"cgi/xsl/
.cc",
\opt\devenv\project\deploy_new_sdk.sh(9): pkill xsl.cgi
\opt\devenv\project\deploy_old_sdk.sh(25):pkill xsl.cgi
\opt\devenv\project\stinst.spec(167):cp ${STPUB}/${OPT}/xsl.cgi ${RPM_BUILD_ROOT}/var/www/cgi-bin
\opt\devenv\project\stinst.spec(2503):/var/www/cgi-bin/xsl.cgi

Expected result:
Files in the search result should contain paths separated by "/", and not "", since I am on Linux, not Windows, so it makes it impossible for me to open that file in Vim for instance, without first replacing all "" with "/".
So, the output should be like:
/opt/devenv/project/build.shinobi(465): "xsl.cgi":{"files":"cgi/xsl/*.cc"

qgrep should find out on which platform it runs, and display the paths according to this.

High cpu & threads

For a large filesystem the first update takes a lot of time and puts the whole server to 100% cpu for hours. Is there a way to optimize this, for e.g:

  • Slow scan, takes longer but doesn't choke the CPU
  • Limit threads
  • I am not sure whether if I kill the process after , say 15 mins, it will resume the scan from the same point. If the update is resumable that also can help a lot!

Assertion failed in build.cpp

I get

Assertion failed: context->pendingSize == 0 && context->pendingFiles.empty(), file C:\Users\brianc\projects\tools\external\qgrep\src\build.cpp, line 678

when I run qgrep update

I've been using this for about a month, no problems until now. Anything obvious I can look for, or check? Thanks,

Error reading .cfg file

Hi I have an issue on Linux, trying to create db files in an alternative directory
(system drive is 250gb nvme, so ~/.qgrep is no good for large datasets).

I specify the init and update commands with explicit pathways instead of a project name, as suggested in README.md.
Files are indexed/created, it seems to run without issue.

When trying to run a search (again using explicit pathway to .cfg file), I get error "Unable to read file.cfg".

I have created test directories on mounted internal drives, set permissions to 777 for pathway and all files to rule out permissions.

Are you able to replicate this?

Assertion failure in build.cpp

I was using the watch command and used git to update the watched folder contents by switching the branch.
qgrep crashed around that time, tell me what kind of details I can provide even though it will probably be hard to reproduce.

C:\project>qgrep watch main
Watching C:\Users\Admin/.qgrep/main.cfg:
Watching folder C:/project...
Listening for changes
Updating C:\Users\Admin/.qgrep/main.cfg:
Assertion failed: file.startLine < startLine, file D:\a\qgrep\qgrep\src\build.cpp, line 583

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.