test emtry directory

This commit is contained in:
yanxd 2014-04-15 14:42:00 +08:00
parent bde4e0f4f7
commit 3081bff9f4
1 changed files with 1 additions and 1 deletions

View File

@ -25,7 +25,7 @@ class TestController < ApplicationController
def ziping files_path def ziping files_path
folder = "#{Rails.root}/files" folder = "#{Rails.root}/files"
input_filename = files_path input_filename = files_path
zipfile_name = "#{Rails.root}/tmp/archive_#{Time.now.to_i}.zip" zipfile_name = "#{Rails.root}/tmp/archiveZip/archive_#{Time.now.to_i}.zip"
Zip::File.open(zipfile_name, Zip::File::CREATE) do |zipfile| Zip::File.open(zipfile_name, Zip::File::CREATE) do |zipfile|
input_filename.each do |filename| input_filename.each do |filename|