lib/synx/project.rb in synx-0.0.51 vs lib/synx/project.rb in synx-0.0.52
- old
+ new
@@ -16,11 +16,11 @@
set_options(options)
presync_check
Synx::Tabber.increase
Synx::Tabber.puts "Syncing files that are included in Xcode project...".bold.white
main_group.all_groups.each { |gr| gr.sync(main_group) }
- puts "\n\n"
+ puts "\n\n" unless options[:quiet]
Synx::Tabber.puts "Syncing files that are not included in Xcode project..".bold.white
main_group.all_groups.each(&:move_entries_not_in_xcodeproj)
transplant_work_project
Synx::Tabber.decrease
save
@@ -46,10 +46,12 @@
else
self.group_exclusions = DEFAULT_EXCLUSIONS
end
self.group_exclusions |= options[:group_exclusions] if options[:group_exclusions]
+
+ Synx::Tabber.quiet = options[:quiet]
end
private :set_options
def transplant_work_project
# Move the synced entries over
@@ -104,9 +106,20 @@
end
end
end
@group_exclusions = new_exclusions
+ end
+
+ def has_object_for_pathname?(pathname)
+ @unmodified_project ||= Synx::Project.open(path)
+ @unmodified_project.objects.any? do |o|
+ begin
+ o.real_path.cleanpath == pathname.cleanpath
+ rescue
+ false
+ end
+ end
end
end
end