92
93
self.flags += " -P '%s'" % (parsed_url.port)
94
95
def _put(self, source_path, remote_filename):
96
remote_path = os.path.join(urllib.unquote(re.sub('^/', '', self.parsed_url.path)), remote_filename).rstrip()
96
97
commandline = "ncftpput %s -m -V -C '%s' '%s'" % \
97
98
(self.flags, source_path.name, remote_path)
98
99
self.subprocess_popen(commandline)
100
101
def _get(self, remote_filename, local_path):
102
remote_path = os.path.join(urllib.unquote(re.sub('^/', '', self.parsed_url.path)), remote_filename).rstrip()
102
103
commandline = "ncftpget %s -V -C '%s' '%s' '%s'" % \
103
104
(self.flags, self.parsed_url.hostname, remote_path.lstrip('/'), local_path.name)
104
105
self.subprocess_popen(commandline)