From 0251ed0b4f01b2813c31af9e5cbfe57dad61340d Mon Sep 17 00:00:00 2001 From: Jörn-Thorben Hinz <11910-jth@users.noreply.salsa.debian.org> Date: Wed, 26 Jan 2022 21:29:04 +0100 Subject: Start bash-completing .deb file paths after the first . passed in an argument to `apt install` This will start by suggesting ./ and ../ which are both fine path segments for `apt install` to handle later. --- completions/bash/apt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'completions') diff --git a/completions/bash/apt b/completions/bash/apt index 61101d839..90b4ef20c 100644 --- a/completions/bash/apt +++ b/completions/bash/apt @@ -189,7 +189,7 @@ _apt() return 0 ;; install) - if [[ "$cur" == ./* || "$cur" == /* || "$cur" == ~* ]]; then + if [[ "$cur" == .* || "$cur" == /* || "$cur" == ~* ]]; then _filedir "deb" else COMPREPLY=( $( apt-cache --no-generate pkgnames "$cur" \ -- cgit v1.2.3-70-g09d2