use excludes on startup rsyncs

This commit is contained in:
Axel Kittenberger 2011-01-19 15:30:19 +00:00
parent 7835de7c7b
commit 117a64d7e1
1 changed files with 6 additions and 2 deletions

View File

@ -869,8 +869,8 @@ local InletFactory = (function()
-- creates a copy
local e = {}
local en = 1;
for _, v in pairs(sync.excludes.list) do
e[en] = v;
for k, _ in pairs(sync.excludes.list) do
e[en] = k;
en = en + 1;
end
return e;
@ -1011,6 +1011,10 @@ local Excludes = (function()
-- this was a ** before
p = string.gsub(p, "%[%^/%]%*%[%^/%]%*", ".*")
p = string.gsub(p, "^/", "^/")
if p.byte(1) ~= 47 then -- does not begin with "/"
-- all matches should begin with "/".
p = "/" .. p;
end
log("Exclude", "toLuaPattern '",o,"' = '",p,'"')
return p
end