Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Android strings.xml convert to csv fromat
# Need "nokogiri" for xml parse
require "nokogiri"
file =[0])
xml_doc = Nokogiri::XML(file)
array = xml_doc.xpath("//string")
str = ""
array.each do |xpath_node|
str.concat( "#{xpath_node.attribute('name')}, #{xpath_node.text}\n")
puts str
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.