Sha256: 52a5f3d7af0680496ce1b9744b305816e141720ab5b7b9fadb2186d210bb2b3c
Contents?: true
Size: 1.52 KB
Versions: 2
Compression:
Stored size: 1.52 KB
Contents
# this code is to list the notes def fillhypernotename(inffile) applet = inffile @a_viewhypernote = applet end def findnotefiles(d) a = Array.new(Dir[d].entries.sort) #loop through and get the files names a.each do |x| #adjust the filters to the files you want to see... if(!test(?d,x)) # only txt files if x =~ /htm|txt|nam|sch|rwd|html/ # puts "#{x}" #opens the file thats in fileName as read only $notesarray = $notesarray | ["#{x}"] end end end end def listnotedirs if $temp_rwdhypernote_directory.to_s.empty? startlangdir = $rwdhypernote_directory else startlangdir = $temp_rwdhypernote_directory end @hypernotetxt_directory = startlangdir $notesarray = [""] #get a list of the files and subdirectories on the starting directory only anotearray = Array.new(Dir[startlangdir].entries.sort) #loop through the list, ignore the files and add all new directories found anotearray.each do |x| #if it is a file... if(!test(?d,x)) anotearray.delete(x) else #it is a directory... findnotefiles(x + "/**") end end @notedirectoriesresult = "" @noterecordsresult = $notesarray.entries.sort.rwd_method("fillhypernotename") end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
rwdhypernote-0.16 | code/superant.com.hypernote/listhypernotes.rb |
rwdhypernote-0.15 | code/superant.com.hypernote/listhypernotes.rb |