]> git.lizzy.rs Git - nhentai.git/blob - README.rst
Update README.rst
[nhentai.git] / README.rst
1 nhentai
2 =======
3
4 .. code-block::
5
6            _   _            _        _
7      _ __ | | | | ___ _ __ | |_ __ _(_)
8     | '_ \| |_| |/ _ \ '_ \| __/ _` | |
9     | | | |  _  |  __/ | | | || (_| | |
10     |_| |_|_| |_|\___|_| |_|\__\__,_|_|
11
12
13 あなたも変態。 いいね?
14
15 |travis|
16 |pypi|
17 |license|
18
19
20 nHentai is a CLI tool for downloading doujinshi from <http://nhentai.net>
21
22 ===================
23 Manual Installation
24 ===================
25 .. code-block::
26
27     git clone https://github.com/RicterZ/nhentai
28     cd nhentai
29     python setup.py install
30
31 ==================
32 Installation (pip)
33 ==================
34 Alternatively, install from PyPI with pip
35 .. code-block::
36
37            pip install nhentai
38
39 For a self-contained installation, use _Pipx:
40 .. code-block::
41
42            pipx install nhentai
43            
44 =====================
45 Installation (Gentoo)
46 =====================
47 .. code-block::
48
49     layman -fa glicOne
50     sudo emerge net-misc/nhentai
51
52 =====
53 Usage
54 =====
55 **IMPORTANT**: To bypass the nhentai frequency limit, you should use `--cookie` option to store your cookie.
56
57 *The default download folder will be the path where you run the command (CLI path).*
58
59
60 Set your nhentai cookie against captcha:
61
62 .. code-block:: bash
63
64     nhentai --cookie "YOUR COOKIE FROM nhentai.net"
65
66 Download specified doujinshi:
67
68 .. code-block:: bash
69
70     nhentai --id=123855,123866
71
72 Download doujinshi with ids specified in a file (doujinshi ids split by line):
73
74 .. code-block:: bash
75
76     nhentai --file=doujinshi.txt
77
78 Search a keyword and download the first page:
79
80 .. code-block:: bash
81
82     nhentai --search="tomori" --page=1 --download
83
84 Download by tag name:
85
86 .. code-block:: bash
87
88     nhentai --tag lolicon --download --page=2
89
90 Download by language:
91
92 .. code-block:: bash
93
94     nhentai --language english --download --page=2
95
96 Download by artist name:
97
98 .. code-block:: bash
99
100     nhentai --artist henreader --download
101
102 Download by character name:
103
104 .. code-block:: bash
105
106     nhentai --character "kuro von einsbern" --download
107
108 Download by parody name:
109
110 .. code-block:: bash
111
112     nhentai --parody "the idolmaster" --download
113
114 Download by group name:
115
116 .. code-block:: bash
117
118     nhentai --group clesta --download
119
120 Download using multiple tags (--tag, --character, --paordy and --group supported):
121
122 .. code-block:: bash
123
124     nhentai --tag "lolicon, teasing" --artist "tamano kedama, atte nanakusa"
125
126 Download your favorites with delay:
127
128 .. code-block:: bash
129
130     nhentai --favorites --download --delay 1
131
132 Format output doujinshi folder name:
133
134 .. code-block:: bash
135
136     nhentai --id 261100 --format '[%i]%s'
137
138 Supported doujinshi folder formatter:
139
140 - %i: Doujinshi id
141 - %t: Doujinshi name
142 - %s: Doujinshi subtitle (translated name)
143 - %a: Doujinshi authors' name
144
145
146 Other options:
147
148 .. code-block::
149
150     Options:
151       # Operation options
152       -h, --help            show this help message and exit
153       -D, --download        download doujinshi (for search results)
154       -S, --show            just show the doujinshi information
155
156       # Doujinshi options
157       --id=ID               doujinshi ids set, e.g. 1,2,3
158       -s KEYWORD, --search=KEYWORD
159                             search doujinshi by keyword
160       --tag=TAG             download doujinshi by tag
161       -F, --favorites       list or download your favorites.
162
163       # Multi-page options
164       --page=PAGE           page number of search results
165       --max-page=MAX_PAGE   The max page when recursive download tagged doujinshi
166
167       # Download options
168       -o OUTPUT_DIR, --output=OUTPUT_DIR
169                             output dir
170       -t THREADS, --threads=THREADS
171                             thread count for downloading doujinshi
172       -T TIMEOUT, --timeout=TIMEOUT
173                             timeout for downloading doujinshi
174       -d DELAY, --delay=DELAY
175                             slow down between downloading every doujinshi
176       -p PROXY, --proxy=PROXY
177                             uses a proxy, for example: http://127.0.0.1:1080
178       -f FILE, --file=FILE  read gallery IDs from file.
179       --format=NAME_FORMAT  format the saved folder name
180
181       # Generating options
182       --html                generate a html viewer at current directory
183       --no-html             don't generate HTML after downloading
184       --gen-main            generate a main viewer contain all the doujin in the folder
185       -C, --cbz             generate Comic Book CBZ File
186       --rm-origin-dir       remove downloaded doujinshi dir when generated CBZ
187                             file.
188
189       # nHentai options
190       --cookie=COOKIE       set cookie of nhentai to bypass Google recaptcha
191
192
193 ==============
194 nHentai Mirror
195 ==============
196 If you want to use a mirror, you should set up a reverse proxy of `nhentai.net` and `i.nhentai.net`.
197 For example:
198
199 .. code-block:: 
200
201     i.h.loli.club -> i.nhentai.net
202     h.loli.club -> nhentai.net
203
204 Set `NHENTAI` env var to your nhentai mirror.
205
206 .. code-block:: bash
207
208     NHENTAI=http://h.loli.club nhentai --id 123456
209
210
211 .. image:: ./images/search.png?raw=true
212     :alt: nhentai
213     :align: center
214 .. image:: ./images/download.png?raw=true
215     :alt: nhentai
216     :align: center
217 .. image:: ./images/viewer.png?raw=true
218     :alt: nhentai
219     :align: center
220
221 ============
222 あなたも変態
223 ============
224 .. image:: ./images/image.jpg?raw=true
225     :alt: nhentai
226     :align: center
227
228
229
230 .. |travis| image:: https://travis-ci.org/RicterZ/nhentai.svg?branch=master
231    :target: https://travis-ci.org/RicterZ/nhentai
232
233 .. |pypi| image:: https://img.shields.io/pypi/dm/nhentai.svg
234    :target: https://pypi.org/project/nhentai/
235
236 .. |license| image:: https://img.shields.io/github/license/ricterz/nhentai.svg
237    :target: https://github.com/RicterZ/nhentai/blob/master/LICENSE
238 .. _Pipx: https://github.com/pipxproject/pipx/