Reshaped "import wiki" feature from command-line to web interface
This commit is contained in:
parent
3e4154de82
commit
06daadc7df
7 changed files with 69 additions and 88 deletions
|
@ -1,3 +1,4 @@
|
|||
require 'fileutils'
|
||||
require 'instiki_errors'
|
||||
|
||||
class FileYard
|
||||
|
@ -6,6 +7,7 @@ class FileYard
|
|||
|
||||
def initialize(files_path)
|
||||
@files_path = files_path
|
||||
FileUtils.mkdir_p(files_path) unless File.exist?(files_path)
|
||||
@files = Dir["#{files_path}/*"].collect{|path| File.basename(path) if File.file?(path) }.compact
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue