Menu

#929 Invalid state for "Find in files"

pending
nobody
None
5
2014-09-20
2013-01-07
No

The "find in files" feature needs help. The most glaring problem is that if the "find in files" popup window has the option "recurse in subfolders". If this checkbox is ever unchecked then it will always produce the error:
"/bin/grep: Source Code: Is a directory"

There is no situation when you can do a "find in files" without giving grep the -R command, grep is complaining because geany is passing in an obviously invalid argument. I suggest removing the "recurse in subfolders" entirely or at the very least have it default enabled... (why would want to find in files but not recursively? what tool does that???)

I really would the directory would stay at my project root! Why do you fight with the user over this? Overall geany is awesome but the "find in files" is super annoying. I just end up using grep on the CLI!

Discussion

  • Lex Trotman

    Lex Trotman - 2013-01-07

    Works for me with Geany 1.23 (git >= 83e7afc) with grep (GNU grep) 2.10 with and without recurse set.

    What platform, Geany version and grep version are you using?

    BTW Geany uses -r not -R

    Non recursive is to limit the search to save time, think a large tree on a remote file system.

     
  • Lex Trotman

    Lex Trotman - 2013-01-07
    • status: open --> pending
     
  • Lex Lythius

    Lex Lythius - 2014-09-15

    Same problem here:

    grep -nHIF -- XXXX (in directory: YYYY) edit.php:119: if ($field_spec->flags & AbstractFieldSpecModel::FLAG_FORCED_VALUE) { /bin/grep: ZZZZ: Is a directory Search failed.

    I'm on Ubuntu 14.04.1 LTS amd64.
    Geany package version: 1.23.1+dfsg-1 (distro vanilla).
    Grep version: 2.16 (distro vanilla).

    Thanks for all your work!

     
  • Lex Lythius

    Lex Lythius - 2014-09-15

    I really would the directory would stay at my project root!

    I think this makes sense too, but this should have its own separate bug/feature request ticket. Did you do that already?

     
  • Nick Treleaven

    Nick Treleaven - 2014-09-20

    I really would the directory would stay at my project root

    See 'Use current file's directory for FiF' checkbox in General/Misc tabs.

     

Log in to post a comment.