Skip to content

Commit

Permalink
(filters) fixed: due to bad rules order some folders and files were n…
Browse files Browse the repository at this point in the history
…ot excluded
  • Loading branch information
Inversion-des committed Aug 6, 2021
1 parent 2e47ca5 commit 4d31f22
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions app/Sync.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2025,11 +2025,14 @@ def active_rules
end
active_rules = inherited_rules + dir_rules
active_rules.sort_by! &:n
#-#!_ o^active_rules
# do not add this dir if exclude branch detected
active_rules.last.and.then do |_|
active_rules.each do |_|
# * here '*' is not the same as '*.*' because latter will skip files w/o extension
if _.exclude_files == ['*'] && _.include_files.empty? && _.with_subdirs?
if !f_dir_excluded && _.exclude_files == ['*'] && _.include_files.empty? && _.with_subdirs?
f_dir_excluded = true
elsif f_dir_excluded && !_.include_files.empty?
f_dir_excluded = false
end
end
if f_dir_excluded && !f_dir_was_excluded
Expand Down

0 comments on commit 4d31f22

Please sign in to comment.