upgraded couchrest for 080
This commit is contained in:
parent
db20bc4101
commit
915905ca13
9 changed files with 40 additions and 20 deletions
|
@ -116,7 +116,11 @@ when "push" # files to views
|
|||
end
|
||||
end
|
||||
# save them to the db
|
||||
control = db.get("#{prefix}/#{cntrl}") rescue nil
|
||||
begin
|
||||
control = db.get("#{prefix}/#{cntrl}")
|
||||
rescue RestClient::Request::RequestFailed
|
||||
control = nil
|
||||
end
|
||||
if (control && control['actions'] == actions)
|
||||
puts "no change to #{prefix}/#{cntrl}. skipping..."
|
||||
else
|
||||
|
|
|
@ -40,7 +40,11 @@ end
|
|||
|
||||
puts attachments.keys.inspect
|
||||
|
||||
doc = @db.get(dirname) rescue nil
|
||||
begin
|
||||
doc = @db.get(dirname)
|
||||
rescue RestClient::Request::RequestFailed
|
||||
doc = nil
|
||||
end
|
||||
|
||||
# puts "get: #{doc.inspect}"
|
||||
|
||||
|
|
|
@ -112,7 +112,11 @@ when "push" # files to views
|
|||
dviews.delete("#{view}-reduce") unless dviews["#{view}-reduce"]["reduce"]
|
||||
end
|
||||
# save them to the db
|
||||
view = db.get("_design/#{design}") rescue nil
|
||||
begin
|
||||
view = db.get("_design/#{design}")
|
||||
rescue RestClient::Request::RequestFailed
|
||||
view = nil
|
||||
end
|
||||
if (view && view['views'] == dviews)
|
||||
puts "no change to _design/#{design}. skipping..."
|
||||
else
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue