With v0.5.3.3, Skarnet released the fix to an oversight that prevented s6-rc from reading data about system services as a non-root user. Now, bash completion scripts for s6-rc are finally possible.
I've written this script in 2022, but felt most users wouldn't benefit if they had to manually change the PKGBUILD to backport the fix.
I made sure it handles the -l and -c options given for the s6-rc programs for accurate completions even when working with user services. s6-rc -l /run/$USER/s6-rc change <TAB> (if you followed the guide on the wiki) will only show your user services.
See attached gifs for examples of it in action.
Installation instructions
1. Clone the repo with the completion scripts: https://github.com/capezotte/s6-shell-completion
2.b. For bash, source bash/s6-rc.bash the end of your .bashrc.
2.z. For zsh, ln -s "$PWD/zsh/s6-rc" ~/.local/share/zsh/functions/s6-rc, and restart zsh (a simple exec zsh should suffice).
I've made zsh completions as well, and created a new git repository containing both:
https://github.com/capezotte/s6-shell-completion
Install instructions are still the same for bash (clone and source s6-rc.bash). For zsh, symlink zsh/s6-rc to ~/.local/share/zsh/functions.
Scripts have been updated to offer the POSIX process group management switches.