Skip to content

Commit

Permalink
feat(janda): bump deps & small breaking changes (#7)
Browse files Browse the repository at this point in the history
* tdd

* cen tenan asui

* small breaking changes

* fix bulk flow

* remake the whole requests with aiohttp

* it should throw something

* tdd 3hentai feature add

* upgrade actions ci

* proper funding links

* add 3hentai docs

* pre release
  • Loading branch information
sinkaroid authored Feb 13, 2023
1 parent 62de178 commit 1783c8e
Show file tree
Hide file tree
Showing 26 changed files with 268 additions and 137 deletions.
3 changes: 1 addition & 2 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
github: sinkaroid
custom: https://paypal.me/sinkaroid
github: sinkaroid
24 changes: 24 additions & 0 deletions .github/workflows/3hentai.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: 3hentai test
on:
push:
branches:
- master
pull_request:
branches:
- master

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Install Python 3
uses: actions/setup-python@v4
with:
python-version: 3.8
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python setup.py install
- name: Download book
run: tomoe --three 608979
8 changes: 4 additions & 4 deletions .github/workflows/asmhentai.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: asmhentai
name: Asmhentai test
on:
push:
branches:
Expand All @@ -11,14 +11,14 @@ jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Install Python 3
uses: actions/setup-python@v1
uses: actions/setup-python@v4
with:
python-version: 3.8
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python setup.py install
- name: Download book
run: make asmhentai
run: tomoe --asmhentai 311851
4 changes: 2 additions & 2 deletions .github/workflows/bulk_download.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Install Python 3
uses: actions/setup-python@v1
with:
Expand All @@ -21,4 +21,4 @@ jobs:
python -m pip install --upgrade pip
python setup.py install
- name: Download from external list
run: make bulk
run: tomoe --bulk doujin.json
8 changes: 4 additions & 4 deletions .github/workflows/hentai2read.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: hentai2read
name: Hentai2read test
on:
push:
branches:
Expand All @@ -11,14 +11,14 @@ jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Install Python 3
uses: actions/setup-python@v1
uses: actions/setup-python@v4
with:
python-version: 3.8
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python setup.py install
- name: Download book
run: make hentai2read
run: tomoe --hentai2read chaldea_life/1
8 changes: 4 additions & 4 deletions .github/workflows/hentaifox.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: hentaifox
name: Hentaifox test
on:
push:
branches:
Expand All @@ -11,14 +11,14 @@ jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Install Python 3
uses: actions/setup-python@v1
uses: actions/setup-python@v4
with:
python-version: 3.8
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python setup.py install
- name: Download book
run: make hentaifox
run: tomoe --hentaifox 59026
8 changes: 4 additions & 4 deletions .github/workflows/nhentai.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: nhentai
name: Nhentai test
on:
push:
branches:
Expand All @@ -11,14 +11,14 @@ jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Install Python 3
uses: actions/setup-python@v1
uses: actions/setup-python@v4
with:
python-version: 3.8
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python setup.py install
- name: Download book
run: make nhentai
run: tomoe --nhentai 255369
8 changes: 4 additions & 4 deletions .github/workflows/pdf.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: pdf render
name: Pdf render test
on:
push:
branches:
Expand All @@ -11,14 +11,14 @@ jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Install Python 3
uses: actions/setup-python@v1
uses: actions/setup-python@v4
with:
python-version: 3.8
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python setup.py install
- name: Download book with pdf render
run: make pdf
run: tomoe --nhentai 255369 --pdf
8 changes: 4 additions & 4 deletions .github/workflows/pururin.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: pururin
name: Pururin test
on:
push:
branches:
Expand All @@ -11,14 +11,14 @@ jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Install Python 3
uses: actions/setup-python@v1
uses: actions/setup-python@v4
with:
python-version: 3.8
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python setup.py install
- name: Download book
run: make pururin
run: tomoe --pururin 47226
8 changes: 4 additions & 4 deletions .github/workflows/simply.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: simplyh
name: Simplyhentai test
on:
push:
branches:
Expand All @@ -11,14 +11,14 @@ jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Install Python 3
uses: actions/setup-python@v1
uses: actions/setup-python@v4
with:
python-version: 3.8
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python setup.py install
- name: Download book
run: make simply
run: tomoe --simply "fate-grand-order/fgo-no-ashibon-fgo-foot-book/all-pages"
38 changes: 0 additions & 38 deletions Makefile

This file was deleted.

33 changes: 18 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<div align="center">
<a href="https://github.com/sinkaroid/tomoe/wiki"><img width="500" src="https://cdn.discordapp.com/attachments/952117487166705747/1013588505919762443/tomoe_.png" alt="tomoe"></a>

<h4 align="center">An exalted doujinshi downloader with ease.</h4>
<h3 align="center">An exalted doujinshi downloader with ease.</h3>
<p align="center">
<a href="https://github.com/sinkaroid/tomoe/actions/workflows/bulk_download.yml"><img src="https://github.com/sinkaroid/tomoe/workflows/modular%20bulk%20download/badge.svg"></a>
<a href="https://codeclimate.com/github/sinkaroid/tomoe/maintainability"><img src="https://api.codeclimate.com/v1/badges/a729e38da1fe1ee520b1/maintainability" /></a>
Expand All @@ -17,7 +17,7 @@ Tomoe is a CLI tool for downloading doujinshi from various doujinboards. It's al

- [Tomoe](#)
- [Features](#features)
- [Tomoe vs. the doujinboards](#tomoe-vs-the-doujinboards)
- [Tomoe availability](#tomoe-vs-the-doujinboards)
- [Site support](#site-support)
- [Installation](#installation)
- [Prerequisites](#prerequisites)
Expand All @@ -40,14 +40,15 @@ Tomoe consumes [Jandapress](https://github.com/sinkaroid/jandapress) and uses [j

**Features availability** Speed or performance may not be accurate because internet connection or API response. Some tests have high resolve time and render a bit longer, because some sources do not provide real extension of an images, tomoe should check and guess it's format.

| Site | Status | Bulk download | Average response | Downloaded |
| --------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------- | ---------------- | --------------------- |
| `nhentai` | [![Nhentai download](https://github.com/sinkaroid/tomoe/workflows/nhentai/badge.svg)](https://github.com/sinkaroid/tomoe/actions/workflows/nhentai.yml) | `Yes` | ~0.52 minutes | ~10.39 MB (26 images) |
| `pururin` | [![Pururin download](https://github.com/sinkaroid/tomoe/workflows/pururin/badge.svg)](https://github.com/sinkaroid/tomoe/actions/workflows/pururin.yml) | `Yes` | ~0.63 minutes | ~15.55 MB (20 images) |
| `hentaifox` | [![Hentaifox download](https://github.com/sinkaroid/tomoe/workflows/hentaifox/badge.svg)](https://github.com/sinkaroid/tomoe/actions/workflows/hentaifox.yml) | `Yes` | ~0.33 minutes | ~8.18 MB (26 images) |
| `hentai2read` | [![Hentai2read download](https://github.com/sinkaroid/tomoe/workflows/hentai2read/badge.svg)](https://github.com/sinkaroid/tomoe/actions/workflows/hentai2read.yml) | `Yes` | ~0.10 minutes | ~7.78 MB (26 images) |
| `simply-hentai` | [![Simply-hentai download](https://github.com/sinkaroid/tomoe/workflows/simplyh/badge.svg)](https://github.com/sinkaroid/tomoe/actions/workflows/simply.yml) | `Yes` | ~0.29 minutes | ~42.61 MB (19 images) |
| `asmhentai` | [![Asmhentai download](https://github.com/sinkaroid/tomoe/workflows/asmhentai/badge.svg)](https://github.com/sinkaroid/tomoe/actions/workflows/asmhentai.yml) | `Yes` | ~0.23 minutes | ~4.96 MB (23 images) |
| Site | Status | Bulk download | Average response |
| --------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------- | ---------------- |
| `nhentai` | [![Nhentai download](https://github.com/sinkaroid/tomoe/workflows/Nhentai%20test/badge.svg)](https://github.com/sinkaroid/tomoe/actions/workflows/nhentai.yml) | `Yes` | ~0.52 minutes |
| `pururin` | [![Pururin download](https://github.com/sinkaroid/tomoe/workflows/Pururin%20test/badge.svg)](https://github.com/sinkaroid/tomoe/actions/workflows/pururin.yml) | `Yes` | ~0.63 minutes |
| `hentaifox` | [![Hentaifox download](https://github.com/sinkaroid/tomoe/workflows/Hentaifox%20test/badge.svg)](https://github.com/sinkaroid/tomoe/actions/workflows/hentaifox.yml) | `Yes` | ~0.33 minutes |
| `hentai2read` | [![Hentai2read download](https://github.com/sinkaroid/tomoe/workflows/Hentai2read%20test/badge.svg)](https://github.com/sinkaroid/tomoe/actions/workflows/hentai2read.yml) | `Yes` | ~0.10 minutes |
| `simply-hentai` | [![Simply-hentai download](https://github.com/sinkaroid/tomoe/workflows/Simplyhentai%20test/badge.svg)](https://github.com/sinkaroid/tomoe/actions/workflows/simply.yml) | `Yes` | ~0.29 minutes |
| `asmhentai` | [![Asmhentai download](https://github.com/sinkaroid/tomoe/workflows/Asmhentai%20test/badge.svg)](https://github.com/sinkaroid/tomoe/actions/workflows/asmhentai.yml) | `Yes` | ~0.23 minutes |
| `3hentai` | [![3hentai download](https://github.com/sinkaroid/tomoe/workflows/3hentai%20test/badge.svg)](https://github.com/sinkaroid/tomoe/actions/workflows/3hentai.yml) | `Yes` | ~0.20 minutes |

## Features

Expand All @@ -69,6 +70,7 @@ Currently tomoe supports the following websites:
- [hentai2read.com](https://hentai2read.com/)
- [simply-hentai.com](https://simply-hentai.com/)
- [asmhentai.com](https://asmhentai.com/)
- [3hentai.net](https://3hentai.net/)

## Prequisites

Expand Down Expand Up @@ -101,11 +103,12 @@ It's fairly simple to use tomoe
| --nhentai, int | nhentai | [`tomoe --nhentai 255369`](https://nhentai.net/g/255369/) |
| --pururin, int | pururin | [`tomoe --pururin 47226`](https://pururin.to/gallery/47226/crot-sampe-lumpuh) |
| --hentaifox, int | hentaifox | [`tomoe --hentaifox 59026`](https://hentaifox.com/gallery/59026/) |
| --hentai2read, str chapter:number | hentai2read | [`tomoe --hentai2read chaldea_life:1`](https://hentai2read.com/chaldea_life/) |
| --hentai2read, str chapter:number | hentai2read | [`tomoe --hentai2read chaldea_life/1`](https://hentai2read.com/chaldea_life/) |
| --simply, str | simply-hentai | [`tomoe --simply "fate-grand-order/fgo-no-ashibon-fgo-foot-book/all-pages"`](https://www.simply-hentai.com/fate-grand-order/fgo-no-ashibon-fgo-foot-book/all-pages) |
| --asmhentai, int | asmhentai | [`tomoe --asmhentai 311851`](https://asmhentai.com/g/311851/) |
| --asmhentai, int | asmhentai | [`tomoe --asmhentai 311851`](https://asmhentai.com/g/311851/)
| --three, int | 3hentai | [`tomoe --three 608979`](https://asmhentai.com/g/311851/) |
| --bulk, str | custom bulk download | [`tomoe --bulk doujin.json`](/doujin.json) |
| --pdf, str | render pdf for each title | [`tomoe --nhentai 255369 --pdf`](https://nhentai.net/g/255369/) |
| --pdf, str | render pdf for each title | [`tomoe --nhentai 255369 --pdf`](https://3hentai.net/d/608979) |

## Bulk download

Expand All @@ -116,7 +119,7 @@ You can pass multiple id to request bulk download
| nhentai | place multiple id | `tomoe --nhentai 255369 417103 417119` |
| pururin | place multiple id | `tomoe --pururin 47226 64351 56175` |
| hentaifox | place multiple id | `tomoe --hentaifox 59026 61805` |
| hentai2read | place multiple `chapter:number` | `tomoe --hentai2read chaldea_life:1 watashitachi_producersan_ni_mechakucha:1` |
| hentai2read | place multiple `chapter:number` | `tomoe --hentai2read chaldea_life/1 watashitachi_producersan_ni_mechakucha/1` |
| simply | place multiple chapter | `tomoe --simply "fate-grand-order/fgo-no-ashibon-fgo-foot-book/all-pages" "original-work/kanchou-manga-cffc37a/all-pages"` |
| asmhentai | place multiple id | `tomoe --asmhentai 311851 210135 309068` |

Expand Down Expand Up @@ -157,7 +160,7 @@ Create `doujin.json` in the same directory where you want to run tomoe and follo
"asmhentai": 210135
},
{
"hentai2read": "chaldea_life:1"
"hentai2read": "chaldea_life/1"
},
{
"simply": "fate-grand-order/fgo-no-ashibon-fgo-foot-book/all-pages"
Expand Down
2 changes: 1 addition & 1 deletion doujin.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"asmhentai": 311851
},
{
"hentai2read": "chaldea_life:1"
"hentai2read": "chaldea_life/1"
},
{
"simply": "fate-grand-order/fgo-no-ashibon-fgo-foot-book/all-pages"
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
url='https://github.com/sinkaroid/tomoe',
project_urls={
"Discord": "https://discord.gg/8wj4vM5hHM",
"Funding": "https://paypal.me/sinkaroid",
"Funding": "https://github.com/sponsors/sinkaroid",
"Issue tracker": "https://github.com/sinkaroid/tomoe/issues/new/choose",
"Documentation": "https://github.com/sinkaroid/tomoe/wiki",
},
Expand Down
3 changes: 2 additions & 1 deletion tomoe/__init__.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
__version__ = "3.0.15"
__version__ = "3.0.17"
from .pururin import get_pur
from .nhentai import get_nh
from .hentaifox import get_hfox
from .hentai2read import get_h2r
from .simplyh import get_sim
from .asmhentai import get_asm
from .threehentai import get_three
from .bulk_download import get_bulk
from .cli import *
from .utils.misc import choose
Loading

0 comments on commit 1783c8e

Please sign in to comment.