GithubHelp home page GithubHelp logo

extract_and_overwrite's Introduction

 This program aims at simplifying the download and extraction of zip files.

 The initial use case is the frequent download and extraction of the same zip files form the same urls. It is a pain to do it by hand, for instance because some OS will rename the path of the extracted files if there is a previous version.

 Without proper configuration, unzipping numerous times the same zip file will result in the creation of numerous directories. Sometimes, you will prefer to overwrite existing ones.
 For instance, if you unzip a file named toto.zip and the directory "toto" already exists, your new data will ne extracted in "toto(1)" then "toto(2)" etc...

 You will find below a quick explanation of the files you have to configure. Please note that by default it uses data from the french chess federation (our use case).

[FILES]
main.py         main program
config.txt      configuration file (see below for format)        
proxy(optional) proxy settings (see below for format)


------------
[config.txt]
------------
For each ZIPFILE you want to donwload, indicate its URL and the PATH it will be stored (cheminZIP). Indicate as well the PATH where it will be unzipped (cheminFILES).

The format is:
[ZIPFILE] NB: it is juste a name
url: URL
cheminZIP: PATH
chemin: PATH


------------
[proxy]
------------
If tour connected through a proxy, this file must be created. The format is a python dictionary where the attributes are the protocols, and the values are the proxy url+ proxy port.

If your proxy for http protocol is "proxy.toto.com" and the port is 666, the proxy file should contain these informations:

{'http':'proxy.toto.com:666}

If for the ftp protocol you have a proxy called proxy.titi.com and the port is 69, your proxy file will be like this:

{'http' : 'proxy.toto.com:666', 'ftp' : 'proxy.titi.com:69'}



extract_and_overwrite's People

Contributors

rundimeco avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.