Skip to content

cmd: auto-complete args starting with a $

Boris Brezillon u-boot 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest2 patches 0 repliesNew

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2common: command: Provide a dollar_complete() helpercommon/command.c env/common.c include/command.h +1 more+70 -70 replies
2/2cmd: mtd: auto-complete args starting with a $ when appropriatecmd/mtd.c+35 -50 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [U-Boot] [PATCH 0/2] cmd: auto-complete args starting with a $

Hello,

It's pretty common to pass arguments that start with a $ and are then expanded by the shell, and I'm this kind of lazy guy that hits tab all the time and expects the shell to suggest something appropriate. So here is a patchset adding support for ${} auto-completion and using the new helper from the mtd command.

Using it elsewhere should be pretty easy (I already patched env set to use it too [1]).

Note that this patch series depends on [2].

Regards,

Boris

[1]https://github.com/bbrezillon/u-boot/commit/9f37c5b6471c7479aa043524d31531f06128771c [2]https://patchwork.ozlabs.org/project/uboot/list/?series=79552

Boris Brezillon (2):
common: command: Provide a dollar_complete() helper
cmd: mtd: auto-complete args starting with a $ when appropriate

 cmd/mtd.c         | 40 ++++++++++++++++++++++++++++++++-----
 common/command.c  | 22 ++++++++++++++++++---
 env/common.c      | 50 ++++++++++++++++++++++++++++++++++++++++++++---
 include/command.h |  2 ++
 include/common.h  |  3 ++-
 5 files changed, 105 insertions(+), 12 deletions(-)
Signature · 1 line
2.17.1