From ad9ac2191bc1a06a8dbbcdf8e3c24ca6d684554d Mon Sep 17 00:00:00 2001 From: Luca Benci Date: Thu, 12 Oct 2017 23:48:49 +0200 Subject: [PATCH] Also accept `{file}` placeholder --- qutebrowser/config/configtypes.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/qutebrowser/config/configtypes.py b/qutebrowser/config/configtypes.py index da77401ac..203c4e573 100644 --- a/qutebrowser/config/configtypes.py +++ b/qutebrowser/config/configtypes.py @@ -1341,9 +1341,12 @@ class ShellCommand(List): if not value: return value - if self.placeholder and '{}' not in ' '.join(value): + if (self.placeholder and + '{}' not in ' '.join(value) and + '{file}' not in ' '.join(value)): raise configexc.ValidationError(value, "needs to contain a " - "{}-placeholder.") + "{}-placeholder or a " + "{file}-placeholder.") return value