lib/autobuild/importer.rb in autobuild-1.7.12.b1 vs lib/autobuild/importer.rb in autobuild-1.7.12.rc1
- old
+ new
@@ -69,10 +69,17 @@
#
# More options are specific to each importer type.
def initialize(options)
@options = options.dup
@options[:retry_count] = Integer(@options[:retry_count] || 0)
+ @repository_id = options[:repository_id] || "#{self.class.name}:#{object_id}"
end
+
+ # Returns a string that identifies the remote repository uniquely
+ #
+ # This can be used to check whether two importers are pointing to the same
+ # repository, regardless of e.g. the access protocol used
+ attr_reader :repository_id
# The number of times update / checkout should be retried before giving up.
# The default is 0 (do not retry)
#
# Set either with #retry_count= or by setting the :retry_count option when