From: Andre Noll Date: Sat, 14 Jun 2025 16:48:21 +0000 (+0200) Subject: Merge topic branch t/completion into master X-Git-Url: https://git.tuebingen.mpg.de/?a=commitdiff_plain;ds=inline;p=paraslash.git Merge topic branch t/completion into master The completers for para_client and para_audioc handle some cases incorrectly or not at all. This series improves on that. * refs/heads/t/completion: Revamp bash_completion. bash completion: Fix help option parsing. audioc: Fix option completion of version and stat. i9e: Introduce i9e_get_nonopt_argnum(). i9e: Introduce i9e_cword_is_option_arg(). i9e: Constify i9e_complete_option(). --- 73659c617719bf40a6cc45faa649c1ebfcce908b diff --cc NEWS.md index 68c8a898,1ed27260..6c9c62b2 --- a/NEWS.md +++ b/NEWS.md @@@ -2,15 -2,9 +2,18 @@@ NEW ==== ------------------------------------------ -?.?.? (to be announced) "pulsating plasma" +0.7.5 (to be announced) "pulsating plasma" ------------------------------------------ +- A bunch of build system improvements and cleanups. +- The special argument '-' to the select subcommand now reactivates + the previous mood or playlist. +- Cleanup of the wma decoder. ++- Tab completion for para_client and para_audioc has been improved ++ substantially. ++ + +Download: [tarball](./releases/paraslash-git.tar.xz) ---------------------------------------- diff --cc interactive.h index 015d8a92,95d19560..86262e9c --- a/interactive.h +++ b/interactive.h @@@ -85,12 -85,15 +85,15 @@@ void i9e_close(void) void i9e_signal_dispatch(int sig_num); __printf_2_3 void i9e_log(int ll, const char* fmt,...); int i9e_poll(struct pollfd *fds, nfds_t nfds, int timeout); - int i9e_extract_completions(const char *word, char **string_list, + int i9e_extract_completions(const char *word, char * const *string_list, char ***result); -char **i9e_complete_commands(const char *word, struct i9e_completer *completers); +char **i9e_complete_commands(const char *word, const struct i9e_completer *completers); - void i9e_complete_option(char **opts, struct i9e_completion_info *ci, - struct i9e_completion_result *cr); + void i9e_complete_option(char * const *opts, + struct i9e_completion_info *ci, struct i9e_completion_result *cr); + unsigned i9e_get_nonopt_argnum(char * const *opts, + struct i9e_completion_info *ci); + int i9e_cword_is_option_arg(char * const *opts, struct i9e_completion_info *ci); -int i9e_print_completions(struct i9e_completer *completers); +int i9e_print_completions(const struct i9e_completer *completers); int i9e_get_error(void); void i9e_ll_completer(struct i9e_completion_info *ci, struct i9e_completion_result *cr);