lib/axlsx.rb in axlsx-1.1.5 vs lib/axlsx.rb in axlsx-1.1.6

- old
+ new

@@ -82,6 +82,13 @@ # ws.rows.first.cells.first.r #=> "A1" def self.cell_r(c_index, r_index) Axlsx::col_ref(c_index).to_s << (r_index+1).to_s end + # performs the increadible feat of changing snake_case to CamelCase + # @param [String] s The snake case string to camelize + # @return [String] + def self.camel(s="") + s = s.capitalize.gsub(/_(.)/){ $1.upcase } + end + end