mirror of
https://github.com/edcommonwealth/sqm-dashboards.git
synced 2026-03-08 23:18:18 -07:00
Only return files in sftp directory, not other directories
This commit is contained in:
parent
03efd88284
commit
798ba1f340
1 changed files with 2 additions and 0 deletions
|
|
@ -9,6 +9,8 @@ module Sftp
|
|||
uri = URI.parse(sftptogo_url)
|
||||
Net::SFTP.start(uri.host, uri.user, password: uri.password) do |sftp|
|
||||
sftp.dir.foreach(path) do |entry|
|
||||
next unless entry.file?
|
||||
|
||||
filename = entry.name
|
||||
puts filename
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue