push forms/ into _design/$this/forms
This commit is contained in:
parent
6b4913e9e8
commit
5a35359f51
1 changed files with 1 additions and 14 deletions
|
@ -174,22 +174,9 @@ module CouchRest
|
||||||
Dir["#{forms_dir}/lib.#{design_lang}"].collect do |global_lib|
|
Dir["#{forms_dir}/lib.#{design_lang}"].collect do |global_lib|
|
||||||
libs << open(global_lib).read
|
libs << open(global_lib).read
|
||||||
libs << "\n"
|
libs << "\n"
|
||||||
end
|
|
||||||
Dir["#{forms_dir}/#{folder}/lib.#{design_lang}"].collect do |global_lib|
|
|
||||||
libs << open(global_lib).read
|
|
||||||
libs << "\n"
|
|
||||||
end
|
end
|
||||||
designs[folder]["forms"]["#{form_name}"] = read(design_doc, libs)
|
designs[folder]["forms"]["#{form_name}"] = read(design_doc, libs)
|
||||||
end
|
end
|
||||||
end
|
|
||||||
|
|
||||||
# # cleanup empty maps and reduces
|
|
||||||
# designs.each do |name, props|
|
|
||||||
# props["forms"].each do |view, funcs|
|
|
||||||
# next unless view.include?("reduce")
|
|
||||||
# props["forms"].delete(view) unless funcs.keys.include?("reduce")
|
|
||||||
# end
|
|
||||||
# end
|
|
||||||
|
|
||||||
designs.each do |k,v|
|
designs.each do |k,v|
|
||||||
create_or_update("_design/#{k}", v)
|
create_or_update("_design/#{k}", v)
|
||||||
|
|
Loading…
Reference in a new issue