Skip to content
This repository has been archived by the owner on Jul 5, 2024. It is now read-only.

Commit

Permalink
Remove update checker logic from main.py (it was checking release num…
Browse files Browse the repository at this point in the history
…bers from the releases github page, which is being depricated). Update readme.md for binary release, and increment version number.
  • Loading branch information
Jules-WinnfieldX committed Mar 25, 2022
1 parent 41da6cb commit a91b817
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 21 deletions.
20 changes: 13 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
| Pixl | Albums: pixl.is/album/... <br> Direct Images: pixl.is/image/... <br> User Profile: pixl.is/#USER# <br> All User Albums: pixl.is/#USER#/albums |
| Bunkr | Albums: bunkr.is/a/... <br> Direct Videos: stream.bunkr.is/v/... <br> Direct Videos: cdn.bunkr.is/... <br> Direct Images: i.bunkr.is/... <br> Also works with Bunkr.to |
| GoFile | Albums: gofile.io/d/... |
| Erome | Albums: erome.com/a/...
| PixelDrain | Albums: Pixeldrain.com/l/... <br> Single Files: Pixeldrain.com/u/...
| Erome | Albums: erome.com/a/... |
| PixelDrain | Albums: Pixeldrain.com/l/... <br> Single Files: Pixeldrain.com/u/... |

# Information

Expand All @@ -24,24 +24,30 @@ You can get Python from here: https://www.python.org/downloads/
It'll repeat that for every link you give it.

# Installation

## Manually
Go to the [releases page](https://github.com/Jules-WinnfieldX/CyberDropDownloader/releases) and download the Cyberdrop_DL.zip file. Extract it to wherever you want the program to be.
## Using `pip`
Once Python is installed, run `pip3 install --user cyberdrop-dl`.

Advanced users may want to use virtual environments (via `pipx`), but it's **NOT** required.

## Manually
_Coming soon..._

# Usage
## Simple way

## Manual way (Manual install above)
Put the links in the URLs.txt file then run Start.bat (Windows) or start.sh (OS X**/Linux**) file.

** Mac and Linux will need to run the command `chmod +x start.sh` to make the file executable.

## Simple (Pip install above)
1. Run `cyberdrop-dl` once to generate an empty `URLs.txt` file.
2. Copy and paste your links into `URLs.txt`.
Each link you add has to go on its own line (paste link, press enter, repeat).
3. Run `cyberdrop-dl` again.
It will begin to download everything.
4. Enjoy!

## Custom way
## Custom way (Pip install above)
If you know what you're doing, you can use some of the available options to adjust how the program runs.
```
$ cyberdrop-dl -h
Expand Down
Empty file removed URLs.txt
Empty file.
2 changes: 1 addition & 1 deletion cyberdrop_dl/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = "2.7.0"
__version__ = "2.7.1"
15 changes: 2 additions & 13 deletions cyberdrop_dl/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
except Exception:
pass


def parse_args():
parser = argparse.ArgumentParser(description="Bulk downloader for multiple file hosts")
parser.add_argument("-V", "--version", action="version", version="%(prog)s " + VERSION)
Expand All @@ -44,18 +45,6 @@ def clear() -> None:
os.system('cls' if os.name == 'nt' else 'clear')


def version_check() -> None:
response = requests.get("https://api.github.com/repos/Jules-WinnfieldX/CyberDropDownloader/releases/latest")
latest_version = response.json()["tag_name"]
logging.debug(f"We are running version {VERSION} of Cyberdrop Downloader")
if latest_version != VERSION:
log("A new version of CyberDropDownloader is available\n"
"Download it here: https://github.com/Jules-WinnfieldX/CyberDropDownloader/releases/latest\n", Fore.RED)
if input("Keep going? (Y/n) ") == "n":
exit()
clear()


def regex_links(urls) -> list:
all_links = [x.group().replace(".md.", ".") for x in re.finditer(r"(?:http.*?)(?=('|$|\n|\r\n|\r|\s)|\")", urls)]
return all_links
Expand All @@ -64,7 +53,7 @@ def regex_links(urls) -> list:
async def download_all(args: argparse.Namespace):
nest_asyncio.apply()
clear()
version_check()
log(f"We are running version {VERSION} of Cyberdrop Downloader", Fore.WHITE)
logging.debug(f"Starting downloader with args: {args.__dict__}")
input_file = Path(args.input_file)
if not os.path.isfile(input_file):
Expand Down

0 comments on commit a91b817

Please sign in to comment.