Compare commits

...

5 Commits

Author SHA1 Message Date
rui 941eef9d54
build: remove travis config (#732)
Signed-off-by: Rui Chen <rui@chenrui.dev>
2022-02-16 08:20:39 +02:00
Arjix 9583a4979d
Update watch.py 2022-02-12 06:00:16 -08:00
Arjix 4b86991945
Update watch.py 2022-02-12 05:19:15 -08:00
Arjix 5ffac4c9a2
Update __version__.py 2022-01-29 02:54:39 -08:00
Arjix 4964463181
Update watch.py 2022-01-29 02:54:28 -08:00
4 changed files with 13 additions and 32 deletions

View File

@ -1,21 +0,0 @@
dist: bionic
language: python
python:
- "3.6"
- "3.7"
- "3.8"
cache: pip
matrix:
fast_finish: true
before_install:
- pip install pytest-cov
install:
- pip install -e ".[dev]"
script:
- python -m pytest tests --cov=.
after_success:
- pip install codecov
- codecov

View File

@ -4,9 +4,6 @@
<strong><i>A simple yet powerful tool for downloading anime.</i></strong>
<br>
<br>
<a href="https://travis-ci.com/anime-dl/anime-downloader">
<img src="https://img.shields.io/travis/com/anime-dl/anime-downloader.svg?style=for-the-badge&logo=Travis%20CI">
</a>
<a href="https://codecov.io/gh/anime-dl/anime-downloader">
<img src="https://img.shields.io/codecov/c/github/anime-dl/anime-downloader.svg?logo=codecov&style=for-the-badge">
</a>
@ -62,7 +59,7 @@ Yeah. Me too! That's why this tool exists.
- Animerush
- AnimeStar
- Animevibe
- Dbanimes
- Dbanimes
- EraiRaws
- EgyAnime - usually m3u8 (good for streaming, not so much for downloading)
- GenoAnime

View File

@ -1 +1 @@
__version__ = '5.0.17'
__version__ = '5.0.18'

View File

@ -7,6 +7,7 @@ import click
import logging
import sys
import re
import os
from anime_downloader import util
from anime_downloader.__version__ import __version__
@ -66,12 +67,9 @@ def command(anime_name, new, update_all, _list, quality, remove,
util.print_info(__version__)
watcher = _watch.Watcher()
with open(watcher.WATCH_FILE, "r") as f:
contents = f.read()
# print(contents)
if "[]" in contents or "[{}]" in contents:
logger.error("Add something to the watch list using `anime watch --new`")
sys.exit(1)
if not os.path.exists(watcher.WATCH_FILE):
with open(watcher.WATCH_FILE, "w") as f:
f.write("[]")
if new:
if anime_name:
@ -84,6 +82,13 @@ def command(anime_name, new, update_all, _list, quality, remove,
watcher.new(url)
sys.exit(0)
with open(watcher.WATCH_FILE, "r") as f:
contents = f.read()
# print(contents)
if "[]" in contents:
logger.error("Add something to the watch list using `anime watch --new`")
sys.exit(1)
if remove:
anime = watcher.get(anime_name)
if anime and click.confirm(