Search notes:

vim script: executable

executable("foo") returns 1 if there is an executable named foo in path and 0 otherwise. If executable() is not implemented, it returns -1.
redir > executable.out

if !executable('reg')
    echo 'reg ist not executable'
    q
endif

echo system('reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts"')
q

"    Arial (TrueType)    REG_SZ    arial.ttf
"    Arial Italic (TrueType)    REG_SZ    ariali.ttf
"    Arial Bold (TrueType)    REG_SZ    arialbd.ttf
"    Arial Bold Italic (TrueType)    REG_SZ    arialbi.ttf
"    ...
"    ...
Github repository about-vim, path: /vimscript/functions/executable.vim

See also

exepath("foo") returns the path to the executable foo.
Vim: built in functions
VIM script

Index

Fatal error: Uncaught PDOException: SQLSTATE[HY000]: General error: 8 attempt to write a readonly database in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php:78 Stack trace: #0 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(78): PDOStatement->execute(Array) #1 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(30): insert_webrequest_('/notes/developm...', 1745531373, '3.12.146.87', 'Mozilla/5.0 App...', NULL) #2 /home/httpd/vhosts/renenyffenegger.ch/httpsdocs/notes/development/vim/script/vimscript/functions/executable(62): insert_webrequest() #3 {main} thrown in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php on line 78