lib/synx/pbx_group.rb in synx-0.0.2 vs lib/synx/pbx_group.rb in synx-0.0.3

- old
+ new

@@ -66,10 +66,14 @@ end private :variant_groups def handle_unused_entry(entry_pathname) if entry_pathname.directory? - project.pathname_to_work_pathname(entry_pathname).mkdir + work_entry_pathname = project.pathname_to_work_pathname(entry_pathname) + # The directory may have already been created for one of two reasons + # 1. It was created as a piece of another path, ie, /this/middle/directory.mkdir got called. + # 2. OS X has case insensitive folder names, so has_entry may have failed to notice it had the folder. + work_entry_pathname.mkdir unless work_entry_pathname.exist? # recurse Synx::Tabber.puts entry_pathname.basename.to_s.green Synx::Tabber.increase entry_pathname.children.each { |child| handle_unused_entry(child) } Synx::Tabber.decrease \ No newline at end of file