[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#44983: Truncate long lines of grep output
From: |
Juri Linkov |
Subject: |
bug#44983: Truncate long lines of grep output |
Date: |
Thu, 10 Dec 2020 10:18:16 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (x86_64-pc-linux-gnu) |
> Perhaps you would like to come up with the name for the new user option?
Maybe something like 'xref-search-truncate' with a number of columns,
nil by default.
>> BTW, for sorting currently xref-search-program-alist uses:
>> "| sort -t: -k1,1 -k2n,2"
>> but fortunately ripgrep has a special option to do the same with:
>> "--sort path"
>
> Somehow, that option came out to be consistently slower in my
> benchmarking. Even when the results are only a few lines (that's actually
> when the difference should be most apparent, because with many lines Elisp
> takes up the most of CPU time). You can try it yourself:
>
> (benchmark 10 '(project-find-regexp ":package-version '(xref"))
>
> 0.86 with '| sort'
> 1.33 with '--sort path'
I confirm that in my tests '--sort path' is 2 times slower than '| sort'.
>> BTW, it's possible to see all highlighted parts of the output
>> by changing the argument 'MODE' of 'compilation-start' in 'grep'
>> from #'grep-mode to t (so it uses comint-mode in grep buffers).
>
> Because ansi-color-process-output is in comint-output-filter-functions?
Exactly.
- bug#44983: Truncate long lines of grep output, (continued)
- bug#44983: Truncate long lines of grep output, Juri Linkov, 2020/12/03
- bug#44983: Truncate long lines of grep output, Juri Linkov, 2020/12/05
- bug#44983: Truncate long lines of grep output, Juri Linkov, 2020/12/06
- bug#44983: Truncate long lines of grep output, Dmitry Gutov, 2020/12/06
- bug#44983: Truncate long lines of grep output, Juri Linkov, 2020/12/06
- bug#44983: Truncate long lines of grep output, Dmitry Gutov, 2020/12/06
- bug#44983: Truncate long lines of grep output, Juri Linkov, 2020/12/08
- bug#44983: Truncate long lines of grep output, Dmitry Gutov, 2020/12/08
- bug#44983: Truncate long lines of grep output, Juri Linkov, 2020/12/09
- bug#44983: Truncate long lines of grep output, Dmitry Gutov, 2020/12/09
- bug#44983: Truncate long lines of grep output,
Juri Linkov <=
- bug#44983: Truncate long lines of grep output, Dmitry Gutov, 2020/12/10
- bug#44983: Truncate long lines of grep output, Jean Louis, 2020/12/09
- bug#44983: Truncate long lines of grep output, Juri Linkov, 2020/12/10
- bug#44983: Truncate long lines of grep output, Jean Louis, 2020/12/10
- bug#44983: Truncate long lines of grep output, Juri Linkov, 2020/12/12
- bug#44983: Truncate long lines of grep output, Eli Zaretskii, 2020/12/13
- bug#44983: Truncate long lines of grep output, Jean Louis, 2020/12/13
- bug#44983: Truncate long lines of grep output, Juri Linkov, 2020/12/13
- bug#44983: Truncate long lines of grep output, Eli Zaretskii, 2020/12/14
- bug#44983: Truncate long lines of grep output, Dmitry Gutov, 2020/12/14