From 16d5d6a9dae526355caf16f2de9d57d84b5d9993 Mon Sep 17 00:00:00 2001 From: Oliver Kiddle Date: Wed, 24 Nov 2021 23:07:18 +0100 Subject: 49597: add a helper for completing numbers with unit suffixes and separate out defaults, ranges and units in completion descriptions --- Completion/Unix/Command/_git | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Completion/Unix/Command/_git') diff --git a/Completion/Unix/Command/_git b/Completion/Unix/Command/_git index 7c7fb22bc..c757376b0 100644 --- a/Completion/Unix/Command/_git +++ b/Completion/Unix/Command/_git @@ -3720,8 +3720,8 @@ _git-fast-import () { now\:"use current time and timezone"' \ '--done[terminate with error if there is no "done" command at the end of the stream]' \ '--force[force updating modified existing branches]' \ - '--max-pack-size=-[maximum size of each packfile]: : __git_guard_bytes' \ - '--big-file-threshold=-[maximum size of blob to create deltas for]: : __git_guard_bytes' \ + '--max-pack-size=-[maximum size of each packfile]: : __git_guard_bytes -d unlimited size' \ + '--big-file-threshold=-[maximum size of blob to create deltas for]: : __git_guard_bytes -d 512m size' \ '--depth=-[maximum delta depth for blob and tree deltification]: :__git_guard_number "maximum delta depth"' \ '--active-branches=-[maximum number of branches to maintain active at once]: :__git_guard_number "maximum number of branches"' \ '--export-marks=-[dump internal marks table when complete]: :_files' \ @@ -7506,7 +7506,7 @@ __git_guard_number () { (( $+functions[__git_guard_bytes] )) || __git_guard_bytes () { - _guard '[[:digit:]]#([kKmMgG]|)' ${*:-size} + _numbers -u bytes ${*:-size} k m g } (( $+functions[__git_datetimes] )) || -- cgit 1.4.1