Created
September 5, 2013 12:17
-
-
Save clauswitt/6449381 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
xml = items.select {|item| item[:title].downcase.start_with?(ARGV[0].downcase) }.map { |item| "<item uid=\"activity\" arg=\"#{item[:title]}\"><title>#{item[:title]}</title><subtitle>Concentrate on #{item[:title]}</subtitle><icon>icon.png</icon></item>"}.join('') | |
puts "<items>#{xml}</items>" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment