Module: Watchit::Render

Included in:
WatchitApp
Defined in:
lib/watchit/render.rb

Instance Method Summary collapse

Instance Method Details

#file_list_html(path) ⇒ Object



3
4
5
6
7
8
9
10
# File 'lib/watchit/render.rb', line 3

def file_list_html(path)
  file_list = Dir.entries(path)
              .select{|name| !name.start_with? '.'}
          erb :file_list, :locals => {
    :path => path,
              :file_list => file_list
          }
end