Module: Ftpd::ListPath
- Included in:
- Session
- Defined in:
- lib/ftpd/list_path.rb
Overview
Functions for manipulating LIST and NLST arguments
Instance Method Summary collapse
-
#list_path(argument) ⇒ String
Turn the argument to LIST/NLST into a path.
Instance Method Details
#list_path(argument) ⇒ String
Turn the argument to LIST/NLST into a path
Although compliant with the spec, this function does not do these things that traditional Unix FTP servers do:
-
Allow multiple paths
-
Handle switches such as “-a”
See: cr.yp.to/ftp/list.html sections “LIST parameters” and “LIST wildcards”
23 24 25 26 27 |
# File 'lib/ftpd/list_path.rb', line 23 def list_path(argument) argument ||= '.' argument = '' if argument =~ /^-/ argument end |