Skip to content

Latest commit

 

History

History
 
 

ftp-tools

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 

Some simple FTP tools.

ftp_info.py

List information about the biggest files on a FTP server.

usage: ftp_info.py [-h] [-p PATH] [-v {0,1,2}] host username password

List information about the biggest files on a FTP server.

positional arguments:
  host                  FTP server address, e.g.: ftp.domain.tld
  username              FTP user name
  password              FTP password

optional arguments:
  -h, --help            show this help message and exit
  -p PATH, --path PATH  root path to start the tree walk
  -v {0,1,2}, --verbosity {0,1,2}
                        increase output verbosity

(run python ftp_info.py -h for current arguments/parameters.)

delete_old_files.py

Cleanup a FTP Server by deleting the files which are older than X days.

usage: delete_old_files.py [-h] [-p PATH] [-v {0,1,2}]
                           [-d {7,8,9,10,11,12,13,14,15,16,17,18,19}]
                           host username password

Cleanup a FTP Server by deleting the files which are older than X days.

positional arguments:
  host                  FTP server address, e.g.: ftp.domain.tld
  username              FTP user name
  password              FTP password

optional arguments:
  -h, --help            show this help message and exit
  -p PATH, --path PATH  root path to start the tree walk
  -v {0,1,2}, --verbosity {0,1,2}
                        increase output verbosity
  -d {7,8,9,10,11,12,13,14,15,16,17,18,19}, --days {7,8,9,10,11,12,13,14,15,16,17,18,19}
                        how many days must a file be old for delete?

(run python delete_old_files.py -h for current arguments/parameters.)

Notes

  • It's not a clean implementation
  • specialised for a MS FTP Server
  • intended for execution under windows
  • min. Python 2.7 needed

DoTo

  • merge duplicated code parts
  • code cleanup

History

  • v0.0.1 - add a CLI
  • v0.0.0 - Initial checkin