Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

5
  • Here is a kind of BASH script, it is not-bad is what I can say :) stackoverflow.com/a/20209457/2067125 Commented Mar 26, 2014 at 7:49
  • What about using the standard file command? Commented Dec 8, 2014 at 14:22
  • 5
    For anyone wanting to do this on a Mac (tested on OS X 10.9.5): ls -l | egrep '^[^d]..x..x..x.*$' The above will list all executables (for all/user and group) in the current directory. Note: The -executable option does not work on a Mac hence the above workaround.
    – techfoobar
    Commented Dec 8, 2014 at 14:28
  • Also relevant: Unix find: search for executable files
    – Slothworks
    Commented Aug 14, 2015 at 6:10
  • 1
    @techfoobar: The question is ambiguous: Does it mean files that contain executable code, or does it mean files that have executable permission?  But even if we assume that executable permission is what is wanted (as the majority of the responses seem to), the question doesn't say world-executable.  Your solution will find files (and also fifos, sockets, symlinks, etc.) that have world execute permission, but not 750 (-rwxr-x---), which is still executable to some users. Commented Feb 20, 2016 at 3:06