awful.completion: add more chars to bash_escape

Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
Julien Danjou 2009-01-10 14:13:07 +01:00
parent d02403e6b9
commit 6143e58190
1 changed files with 6 additions and 2 deletions

View File

@ -40,8 +40,12 @@ function bashcomp_load(src)
end
local function bash_escape(str)
res = str:gsub(" ", "\\ ")
return res
str = str:gsub(" ", "\\ ")
str = str:gsub("%[", "\\[")
str = str:gsub("%]", "\\]")
str = str:gsub("%(", "\\(")
str = str:gsub("%)", "\\)")
return str
end
--- Use bash completion system to complete command and filename.