how to use Plist ???

U

Une bévue

i try to use the gem plist by :
#!/usr/bin/env ruby

require 'plist'
plist=Plist.parse_xml(my_info_path)

and i get :

NameError: uninitialized constant Plist

how do i initialize this constant, i thought it was done into "plist.rb"
starting with :

class Plist

def Plist::parse_xml( filename )
listener = Listener.new
#parser = REXML::parsers::StreamParser.new(File.new(filename),
listener)
parser = StreamParser.new(filename, listener)
parser.parse
listener.result
end



i've allready tested :

plist=Plist::parse_xml(my_info_path)
with the same error message ???
 
U

Une bévue

Une bévue said:
i've allready tested :

plist=Plist::parse_xml(my_info_path)
with the same error message ???

also i should say i have the same prob running "test_plist.rb" included
in the gem package of Plist.

also, i should say i was unable to update Plist and have an old version
: 1...
 
U

Une bévue

Une bévue said:
also i should say i have the same prob running "test_plist.rb" included
in the gem package of Plist.

in fact, this has nothing to do with ruby nor ruby_gems, it comes from
my editor (TextMate) not understanding (?) some env vars...
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,208
Messages
2,571,083
Members
47,683
Latest member
AustinFairchild

Latest Threads

Top