Skip to content

Conversation

@unrealapex
Copy link
Contributor

@unrealapex unrealapex commented Jul 4, 2025

Add completion for abduco, a session manager.

@unrealapex unrealapex marked this pull request as draft July 4, 2025 06:48
Comment on lines 25 to 28
(-A|-a|-f)
# FIXME: figure out why this isn't completing
complete -P "$PREFIX" -- $(abduco | tail -n+2 | awk '{print $NF}')
;;
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What would be the correct way to write this completion?

(-)
command -f completion//completeoptions
;;
(-A|-a|-f)
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If my understanding is correct, session names are specified as the first operand, not as an argument to an option. When completing an operand, $ARGOPT is empty.

Suggested change
(-A|-a|-f)
('')

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Session names are only given as arguments to those three arguments.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You are right. Every abduco command requires session names given as the first operand unless abduco is given no options or using the -v(print version).

unrealapex and others added 2 commits July 22, 2025 01:21
Co-authored-by: WATANABE Yuki <[email protected]>
Co-authored-by: WATANABE Yuki <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants