[
https://issues.apache.org/jira/browse/CASSANDRA-20794?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18112580#comment-18112580
]
Stefan Miklosovic commented on CASSANDRA-20794:
-----------------------------------------------
[~rishabhsaraswat]
This is a great addition but we need to a bit more pedantic about this. We most
probably need to add this to a release tarball and maybe RPM / DEB package too.
Then upon installation of these packages we need to add them to respective
system directories for shell completion. For example, this is directly in
generated autocompletion script:
{code}
# 1a. Alternatively, if you have
[bash-completion](https://github.com/scop/bash-completion) installed:
# Place this file in a `bash-completion.d` folder:
#
# * /etc/bash-completion.d
# * /usr/local/etc/bash-completion.d
# * ~/bash-completion.d
{code}
so I can imagine that this would go to {{/usr/local/etc/bash-completion.d}}
upon the installation of these packages.
We also need to figure out where to put this file in the source tarball, figure
out what licence that file should have or we set it among ignored in {{ant
rat}}.
I do not think it is a good idea to generate this into {{build}} directory.
This file might be committed into the repository. That way when we add a new
command or change it, mere build will regenerate this script so it will be
always aligned.
> Generate autocompletion scripts for the nodetool command during the build
> -------------------------------------------------------------------------
>
> Key: CASSANDRA-20794
> URL: https://issues.apache.org/jira/browse/CASSANDRA-20794
> Project: Apache Cassandra
> Issue Type: Improvement
> Components: Build
> Reporter: Maxim Muzafarov
> Assignee: Rishabh Saraswat
> Priority: Normal
> Fix For: 7.x
>
> Time Spent: 1h
> Remaining Estimate: 0h
>
> All picocli-based applications can have command line completion in Bash or
> ZSH Unix shells. Picocli can generate an autocompletion script tailored to
> your application.
> It may be useful to generate your completion scripts automatically during the
> build.
> See the details below:
> https://picocli.info/autocomplete.html#_generating_completion_scripts_during_the_build
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]