Created
December 4, 2012 05:17
-
-
Save snowe2010/4200868 to your computer and use it in GitHub Desktop.
Scans array elements for tokens then writes them to a file, token_type(t) returns the xml for that token
This file contains 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
@whitespace_clean.each { |t| t.scan(/".*?"|\w+|[\[\]\.\(\){};=,+\-<>~\&\*\/\|]/) {|t| @write_file.write(token_type(t)) }} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment