Sha256: d6275751cce3efbd09deb67c81f313c3e84d8862e4d732ba9a62f9947537a6aa
Contents?: true
Size: 574 Bytes
Versions: 5
Compression:
Stored size: 574 Bytes
Contents
require_relative 'command_handler' module Ftpd class CmdStou < CommandHandler def cmd_stou(argument) close_data_server_socket_when_done do ensure_logged_in ensure_file_system_supports :write path = argument || 'ftpd' path = File.expand_path(path, name_prefix) path = unique_path(path) ensure_accessible path ensure_exists File.dirname(path) contents = receive_file(File.basename(path)) file_system.write path, contents reply "226 Transfer complete" end end end end
Version data entries
5 entries across 5 versions & 1 rubygems
Version | Path |
---|---|
ftpd-0.16.0 | lib/ftpd/cmd_stou.rb |
ftpd-0.15.0 | lib/ftpd/cmd_stou.rb |
ftpd-0.14.0 | lib/ftpd/cmd_stou.rb |
ftpd-0.13.0 | lib/ftpd/cmd_stou.rb |
ftpd-0.12.0 | lib/ftpd/cmd_stou.rb |