bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH] allow quoting completions w/o filename treatment


From: Grisha Levit
Subject: [PATCH] allow quoting completions w/o filename treatment
Date: Fri, 14 Apr 2023 17:20:24 -0400

Currently, there isn't any way to request quoting of completion matches
without getting also the attendant filename treatment.

In practice, authors of completion functions that need the matches to be
quoted often use `-o filenames', which works fine unless the matches
include slashes or happen to match existing directory names.

Alternatively, some authors opt to do their own quoting of matches but
doing so properly for partial word completion is tricky as it requires
accounting for the quoting style chosen by the user when they typed the
partial word.

The attached patch hopefully addresses these difficulties by allowing for
the decoupling of filename-specific match handling from match quoting.

It adds a new completion option `allquote' (I'm not quite happy with the
name) which controls the corresponding new readline variable
rl_all_quoting_desired.

Attachment: 0001-allow-quoting-completions-w-o-filename-treatment.patch
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]