Skip to content
Tcl Source Code View Ticket
Login

View Ticket

auto_execok on Unix does not work for built-in shell commands as documented

Closed / Fixed55e5404b7aec68ef897acc37e3de812d31d48d4bCreated 219 days agoUpdated 197 days ago
Descriptionmarkdown2026-04-28 05:15:42

I am not sure whether this is a documentation bug or implementation bug. The manpage says

Determines whether there is an executable file or shell builtin by the name cmd.
...
For example, to run the umask shell builtin on Linux, you would do:

exec {*}[auto_execok umask]

Note the reference to shell builtin in the example. However, on my Ubuntu 22 system at least, the above does not work, auto_execok returns an empty string.

apnadkarni Ticket [55e5404b7a]: 3 changes [History diff]2026-04-28 05:36:30
dkf Ticket [55e5404b7a]: 3 changes [History diff]2026-05-08 19:00:41
apnadkarniplain2026-05-20 09:02:11
Closing as a documentation fix as part of TIP 755. As far as I can tell, `auto_execok` has never handled shell built-ins on Unix. It's not clear how it could given the different shells.
Log in (anonymous is fine) to add a comment.