From 0bc83193322fdf3f5c64edd9f1bddd768ef6ec49 Mon Sep 17 00:00:00 2001 From: Jani Nikula Date: Wed, 12 Mar 2014 22:33:49 +0200 Subject: [PATCH] [PATCH 2/2] completion: complete directory parameters to directories only --- af/2844490b4e2f16b565672ae061f6cdde09f945 | 97 +++++++++++++++++++++++ 1 file changed, 97 insertions(+) create mode 100644 af/2844490b4e2f16b565672ae061f6cdde09f945 diff --git a/af/2844490b4e2f16b565672ae061f6cdde09f945 b/af/2844490b4e2f16b565672ae061f6cdde09f945 new file mode 100644 index 000000000..6fc217374 --- /dev/null +++ b/af/2844490b4e2f16b565672ae061f6cdde09f945 @@ -0,0 +1,97 @@ +Return-Path: +X-Original-To: notmuch@notmuchmail.org +Delivered-To: notmuch@notmuchmail.org +Received: from localhost (localhost [127.0.0.1]) + by olra.theworths.org (Postfix) with ESMTP id 16743431FDD + for ; Wed, 12 Mar 2014 13:34:03 -0700 (PDT) +X-Virus-Scanned: Debian amavisd-new at olra.theworths.org +X-Spam-Flag: NO +X-Spam-Score: -0.7 +X-Spam-Level: +X-Spam-Status: No, score=-0.7 tagged_above=-999 required=5 + tests=[RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled +Received: from olra.theworths.org ([127.0.0.1]) + by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) + with ESMTP id yoPoXdFbflf7 for ; + Wed, 12 Mar 2014 13:33:57 -0700 (PDT) +Received: from mail-ee0-f44.google.com (mail-ee0-f44.google.com + [74.125.83.44]) (using TLSv1 with cipher RC4-SHA (128/128 bits)) (No client + certificate requested) by olra.theworths.org (Postfix) with ESMTPS id + 57709431FC0 for ; Wed, 12 Mar 2014 13:33:57 -0700 + (PDT) +Received: by mail-ee0-f44.google.com with SMTP id e49so18719eek.31 + for ; Wed, 12 Mar 2014 13:33:54 -0700 (PDT) +X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; + d=1e100.net; s=20130820; + h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to + :references; + bh=gELiUbRWvzc+cdf6GTfSoNAO+AaAssqGTh/7yGtB7yE=; + b=fD4aaAk0FxokNzXNJPsgzQ//onsvtnDIgI98HsOfTgi1PxxYOjONQI0Cx+Fkwu32wE + cUDN2SzkUVW0lJInGg3FqNTFjlDmVGPwz93fClvXz93+8/PozKSZL4OKwvTFupBEh51x + 2nma1FGwrwvkTrW9cHYrGgWtBuuj87FhFd1KTDx7mjcRfUy/X+ilRm/SR3e35ztkltRi + M06scupHmV+XrEhkUbKT7S3VpsAejsy4l3nirGmtcbTEZpPUVFfzq71Vx/ET2JukW4jS + Om1RbgfCcMWs9TSKH54fx/a3wsSYZyJnbN/mJp6mQjkFJkA8bLmI5BbKTVTNyWPCAx4R + RDQw== +X-Gm-Message-State: + ALoCoQli4K+iCzfCzNghm9OSRGewNvnKWHTp0QkgvDA9YrVJ9UrsHiHLc9vF2F1Fryv1WqR7GJ0k +X-Received: by 10.14.198.197 with SMTP id v45mr34563264een.9.1394656434802; + Wed, 12 Mar 2014 13:33:54 -0700 (PDT) +Received: from localhost (dsl-hkibrasgw2-58c36f-91.dhcp.inet.fi. + [88.195.111.91]) + by mx.google.com with ESMTPSA id m1sm11636een.7.2014.03.12.13.33.53 + for + (version=TLSv1.2 cipher=RC4-SHA bits=128/128); + Wed, 12 Mar 2014 13:33:54 -0700 (PDT) +From: Jani Nikula +To: notmuch@notmuchmail.org +Subject: [PATCH 2/2] completion: complete directory parameters to directories + only +Date: Wed, 12 Mar 2014 22:33:49 +0200 +Message-Id: <1394656429-1409-2-git-send-email-jani@nikula.org> +X-Mailer: git-send-email 1.9.0 +In-Reply-To: <1394656429-1409-1-git-send-email-jani@nikula.org> +References: <1394656429-1409-1-git-send-email-jani@nikula.org> +X-BeenThere: notmuch@notmuchmail.org +X-Mailman-Version: 2.1.13 +Precedence: list +List-Id: "Use and development of the notmuch mail system." + +List-Unsubscribe: , + +List-Archive: +List-Post: +List-Help: +List-Subscribe: , + +X-List-Received-Date: Wed, 12 Mar 2014 20:34:03 -0000 + +i.e. don't complete to files if only directories are acceptable. +--- + completion/notmuch-completion.bash | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/completion/notmuch-completion.bash b/completion/notmuch-completion.bash +index 59f1a3ea6431..d88c5e7d965e 100644 +--- a/completion/notmuch-completion.bash ++++ b/completion/notmuch-completion.bash +@@ -78,7 +78,7 @@ _notmuch_compact() + $split && + case "${prev}" in + --backup) +- _filedir ++ _filedir -d + return + ;; + esac +@@ -107,7 +107,7 @@ _notmuch_config() + ;; + # these will also complete on config get, but we don't care + database.path) +- _filedir ++ _filedir -d + ;; + maildir.synchronize_flags) + COMPREPLY=( $(compgen -W "true false" -- ${cur}) ) +-- +1.9.0 + -- 2.26.2