Skip to content

rg --vimgrep shows multiple lines #293

@agriffis

Description

@agriffis
  • Emacs 25.1.1
  • Fedora 25
  • ripgrep 0.3.2
  • helm-ag--last-command is ("rg" "--smart-case" "--no-heading" "--vimgrep" "asdf")

Actual behavior

multiple lines returned for a single line containing multiple instances of the same value

screenshot from 2017-02-17 11-37-32

Expected behavior

just show one result, like ag does

Notes

helm-ag has this code for ag:

(defcustom helm-ag-base-command
  (if (helm-ag--windows-p)
      "ag --vimgrep"
    "ag --nocolor --nogroup")
  "Base command of `ag'"
  :type 'string)

I'm not sure why this uses --vimgrep on Windows and not on other platforms, but it could be the reason for the discrepancy we're seeing between ag and rg. What do you recommend?

References

syl20bnr/spacemacs#7370 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions