Solved doas no auto complete using tab


Active Member

Reaction score: 111
Messages: 248

HI All

I have installed and set up doas(1).
But you can't auto complete the first command after doas(1) using the tab key.

For example if I want to use doas(1) to mount a NFS share.

I would run: doas mount ~/video

But mount won't auto complete using the tab key.
It's not just the mount command any command after doas(1) won't auto complete with the tab key.

So if you type: doas mou + tab it won't auto complete to mount

I have /usr/local/etc/doas.conf with the following contents:
permit nopass keepenv :wheel
permit nopass keepenv root as root
I'm in the wheel group and I can run commands without entering my password using the nopass option
It's just auto complete doesn't work.

I have rehashed the shell, I'm running bash(1) but that didn't make any difference.

A couple of other things I have noticed using doas(1).

The persist option only works on OpenBSD, so if you use persist it will prompt you for your password every time you use doas(1) and it won't remember the password for 5 minutes like sudo(8).

I tried using doas(1) with emacs tramp but it just hangs saying waiting for prompt.
I tried the nopass and persist option and both had the same issue, I think it's a tramp specific issue.


Active Member

Reaction score: 111
Messages: 248

Hi Mate

adding complete -cf doas to ~/.bashrc works like a charm