Function: file-executable-p

file-executable-p is a function defined in fileio.c.

Signature

(file-executable-p FILENAME)

Documentation

Return t if FILENAME can be executed by you.

For a directory, this means you can access files in that directory.
(It is generally better to use file-accessible-directory-p for that
purpose, though.)

Other relevant functions are documented in the file group.

Shortdoc

;; file
(file-executable-p "/bin/cat")
    e.g. => t

Aliases

f-executable? f-executable-p

Source Code

// Defined in /usr/src/emacs/src/fileio.c
{
  return check_file_access (filename, Qfile_executable_p, X_OK);
}