Update README.md

This commit is contained in:
tianyu 2015-08-17 13:09:34 +08:00
parent c07e3018b7
commit db63dbc5a9
1 changed files with 31 additions and 1 deletions

View File

@ -1 +1,31 @@
This script will download *.zip and *.img files from `http://download.cyanogenmod.org/` and then upload it to baiduyun
This script will download `*.zip` and `*.img` files from [http://download.cyanogenmod.org/](http://download.cyanogenmod.org/) and then upload it to baiduyun.
## Dependency
This tool requires `python3` `bypy` `python3-bs4`
```
apt-get install python3 python3-bs4
git clone https://github.com/houtianze/bypy
```
## Usage
Make sure the paths is `/root/bypy/bypy.py` `/root/cm/cm.py`, otherwise you have to modify the script for your need.
**Upload**
```
cd ~/cm/
screen
./cm.py
```
This will fetch `http://download.cyanogenmod.org/` and download `*.zip` `*.img` and check their `sha1`. Then upload it to baiduyun.
The default download directory is `/var/cyanogenmod`, and the default upload directory is `/YOUR_APP_DIR/cm/DEVICE`. Log file is saved in `/var/cyanogenmod/DEVICE/log/DEVICE.log`.
**Generate device list**
```
./cm.py --list
```