Giter Club home page Giter Club logo

inmangakindle's Introduction

Manga en Español para Kindle / Ebook

Spanish Manga for Kindle / Ebook

ko-fi

Instalar / Install

Python

🇪🇸: Las dependencias de Python se instalarán automáticamente la primera vez que ejecutes el programa.

También puedes instalarlas manualmente con el siguiente comando:

pip install --user -r dependencies.txt

A veces el comando para Python3 es pip3 en lugar de pip.

🇬🇧: Python dependencies will be installed automatically the first time you run the program.

Dependencies can also be installed manually with the following command:

pip install --user -r dependencies.txt

Sometimes dependencies command for Python3 is pip3 instead of pip.

Instalará / Will install:

MOBI / Kindle

Para convertir un manga al formato MOBI (Kindle) necesitarás instalar KindleGen y añadirlo al PATH. Tienes dos formas de hacerlo:

Kindle Previewer 3

KindleGen está incluido en Kindle Previewer 3. Una vez descargado:

  • Windows: El instalador de Kindle Previewer añadirá KindleGen al PATH automáticamente.
  • Mac OSX: cp /Applications/Kindle\ Previewer\ 3.app/Contents/lib/fc/bin/kindlegen /usr/local/bin/kindlegen
Manualmente

Si no quieres descargar Kindle Previewer puedes descargar el binario kindlegen manualmente aquí. Una vez descargado:

  • Windows: Sigue estas instrucciones para añadir al PATH la carpeta donde hayas descargado kindlegen.
  • Mac OSX: mv ~/Descargas/kindlegen /usr/local/bin/kindlegen
SendToKindle

Puedes enviar tus capítulos directamente al Kindle con la aplicación SendToKindle.

PDF

En la conversión a PDF algunas imágenes pueden dar el error Exception: Refusing to work on images with alpha channel. Para corregir esto se debe eliminar la transparencia de estas imágenes. Puedes añadir la opción --remove-alpha para hacerlo automáticamente. Para que funcione debes instalar Wand + ImageMagick.

🇪🇸 Uso

Tutorial en vídeo

A veces el comando python3 es simplemente python. Comprueba que la versión sea superior a 3.6 con python --version o python3 --version.

python3 manga.py -h

uso: manga.py [-h] [--chapters CHAPTERS] [--directory DIRECTORY] [--single]
                [--rotate] [--profile PROFILE] [--format FORMAT] [--fullsize]
                [--cache] [--remove-alpha]
                manga

parámetros posicionales:
  manga                 título del manga a descargar

parámetros opcionales:
  -h, --help            muestra este mensaje de ayuda (en inglés)
  --chapters CHAPTERS, --chapter CHAPTERS
                        capítulos a descargar. Formato: primero..último o capítulos
                        con comas. Ejemplo: --chapters "3..last" descargará
                        los capítulos del 3 hasta el último disponible.
                        --chapter 3 descarga sólo el capítulo 3,
                        "3, 12" descarga el 3 y el 12, --chapters
                        "3..12, 15" descarga desde el 3 hasta el 12 y
                        también el capítulo 15. Si este argumento no se proporciona
                        se descargarán todos los capítulos disponibles.
  --directory DIRECTORY
                        directorio/carpeta para guardar las descargas. Por defecto: ./manga
  --single              empaqueta los capítulos en un único archivo. Si este parámetro no se proporciona
                        cada capítulo se creará en un fichero independiente.
  --rotate              rota las dobles páginas. Si este parámetro no se proporciona
                        las dobles páginas se dividirán en dos páginas separadas.
  --profile PROFILE     Dispositivo (Opciones disponibles: K1, K2, K34, K578,
                        KDX, KPW, KV, KO, KoMT, KoG, KoGHD, KoA, KoAHD,
                        KoAH2O, KoAO) [Por defecto = KPW (Kindle Paperwhite)]
  --format FORMAT       Formato de salida (Opciones disponibles: PNG, PDF, MOBI, EPUB,
                        CBZ) [Por defecto = MOBI]. Si se selecciona PNG entonces no
                        se hará ninguna conversión.
  --fullsize            con este parámetro no se ajustará el tamaño de las imágenes al perfil del dispositivo
  --cache               Utiliza las imágenes en local sin descargar ningún capítulo (modo sin conexión)
  --remove-alpha        Elimina el canal alpha de las imagenes en la conversión a PDF usando ImageMagick

🇪🇸 Ejemplos

La resolución de pantalla por defecto está ajustada para Kindle Paperwhite. Utiliza la opción --profile para cambiar el perfil a tu dispositivo.

  • python3 manga.py "one piece" --chapters 880..last --single descargará los capítulos desde el 880 hasta el último disponible del manga One Piece y los empaquetará en un único archivo MOBI
  • python3 manga.py "one piece" --chapters 880..last --format PDF --single hace lo mismo que el ejemplo anterior pero en formato PDF para leer en el ordenador
  • python3 manga.py "shingeki no kyojin" --chapter last --format EPUB descargará el último capítulo de Shingeki no Kyojin como EPUB
  • python3 manga.py "dragon ball" --chapters "1, 2, 8..11" descargará los capítulos 1, 2, 8, 9, 10, 11 de Dragon Ball en diferentes archivos MOBI
  • python3 manga.py "one piece" --chapters 900..910 --single --rotate --cache utilizará los capítulos descargados previamente para crear un archivo MOBI con los capítulos del 900 al 910 de One Piece. También girará las páginas dobles para verlas en horizontal en lugar de dos páginas diferentes.

🇬🇧 Usage

Sometimes python3 command is just python. Check that your version is greater than 3.6 with python --version or python3 --version.

python3 manga.py -h

usage: manga.py [-h] [--chapters CHAPTERS] [--directory DIRECTORY] [--single]
                [--rotate] [--profile PROFILE] [--format FORMAT] [--fullsize]
                [--cache] [--remove-alpha]
                manga

positional arguments:
  manga                 manga to download

optional arguments:
  -h, --help            show this help message and exit
  --chapters CHAPTERS, --chapter CHAPTERS
                        chapters to download. Format: start..end or chapters
                        with commas. Example: --chapters "3..last" will
                        download chapters from 3 to the last chapter,
                        --chapter 3 will download only chapter 3, --chapters
                        "3, 12" will download chapters 3 and 12, --chapters
                        "3..12, 15" will download chapters from 3 to 12 and
                        also chapter 15. If this argument is not provided all
                        chapters will be downloaded.
  --directory DIRECTORY
                        directory to save downloads. Default: ./manga
  --single              merge all chapters in only one file. If this argument
                        is not provided every chapter will be in a different
                        file
  --rotate              rotate double pages. If this argument is not provided
                        double pages will be splitted in 2 different pages
  --profile PROFILE     Device profile (Available options: K1, K2, K34, K578,
                        KDX, KPW, KV, KO, KoMT, KoG, KoGHD, KoA, KoAHD,
                        KoAH2O, KoAO) [Default = KPW (Kindle Paperwhite)]
  --format FORMAT       Output format (Available options: PNG, PDF, MOBI,
                        EPUB, CBZ) [Default = MOBI]. If PNG is selected then
                        no conversion to e-reader file will be done
  --fullsize            Do not stretch images to the profile's device
                        resolution
  --cache               Avoid downloading chapters and use already downloaded
                        chapters instead (offline)
  --remove-alpha        When converting to PDF remove alpha channel on images
                        using ImageMagick Wand

🇬🇧 Examples

Default screen resolution is for Kindle Paperwhite device profile. Use option --profile to change the profile to your device.

  • python3 manga.py "one piece" --chapters 880..last --single will download One Piece chapters from 880 to the last chapter available and pack them into one single MOBI file
  • python3 manga.py "one piece" --chapters 880..last --format PDF --single will result in the same as above but in PDF instead MOBI
  • python3 manga.py "shingeki no kyojin" --chapter last --format EPUB will download the last chapter of Shingeki no Kyojin as EPUB
  • python3 manga.py "dragon ball" --chapters "1, 2, 8..11" will download chapters 1, 2, 8, 9, 10, 11 of Dragon Ball as different MOBI files
  • python3 manga.py "one piece" --chapters 900..910 --single --rotate --cache will reuse chapters previously downloaded to create a new MOBI file with One Piece chapters from 900 to 910. Double pages will be rotated to read horizontally instead of two splitted pages.

inmangakindle's People

Contributors

carleslc avatar digitalizarte avatar tolete12 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

inmangakindle's Issues

Idioma

Falta una opcion para seleccionar en que idioma quieres el manga, ya que te lo baja en ingles

Choosing png format try to convert to EPUB and crash

If manga.py is executed as follow:

foo@var:~/git/InMangaKindle$ python3.6 manga.py --format png --chapters "last" Berserk
Searching Berserk...
Downloading Berserk 357
Page 1/16 (6%)
Page 2/16 (12%)
Page 3/16 (18%)
Page 4/16 (25%)
Page 5/16 (31%)
Page 6/16 (37%)
Page 7/16 (43%)
Page 8/16 (50%)
Page 9/16 (56%)
Page 10/16 (62%)
Page 11/16 (68%)
Page 12/16 (75%)
Page 13/16 (81%)
Page 14/16 (87%)
Page 15/16 (93%)
Page 16/16 (100%)
Converting to PNG...
Berserk 357
Preparing source images...
Checking images...
Processing images...
Creating EPUB file...
Traceback (most recent call last):
  File "manga.py", line 314, in <module>
    os.rename(f'{MANGA_DIR}/{chapter}{extension}', path)
FileNotFoundError: [Errno 2] No such file or directory: './manga/357.png' -> './manga/Berserk 357.png'

The script try to create a EPUB with a incorrect extension. I don't know if this step shall be skipped. Same error happen with CBR and CBZ format. The script appear to work using option --format epub:

foo@var:~/git/InMangaKindle$ python3.6 manga.py --format epub --chapters "last" Berserk
Searching Berserk...
Downloading Berserk 357
Page 1/16 (6%)      - Already exists
Page 2/16 (12%)     - Already exists
Page 3/16 (18%)     - Already exists
Page 4/16 (25%)     - Already exists
Page 5/16 (31%)     - Already exists
Page 6/16 (37%)     - Already exists
Page 7/16 (43%)     - Already exists
Page 8/16 (50%)     - Already exists
Page 9/16 (56%)     - Already exists
Page 10/16 (62%)    - Already exists
Page 11/16 (68%)    - Already exists
Page 12/16 (75%)    - Already exists
Page 13/16 (81%)    - Already exists
Page 14/16 (87%)    - Already exists
Page 15/16 (93%)    - Already exists
Page 16/16 (100%)   - Already exists
Converting to EPUB...
Berserk 357
Preparing source images...
Checking images...
Processing images...
Creating EPUB file...
DONE: /home/foo/git/InMangaKindle/manga/Berserk 357.epub

Thank you very much for the repository and your time.

Http Error 522 al intentar descargar

Buenas, parece ser que al intentar descargar los mangas desde InManga esta arrojando error 522 impidiendo así poder descargar los capitulos.

Entiendo que esto es un Scrapper de InManga pero hay alguna prevision para poder utilizar alguna pagina diferente?

Gracias

kindlegen

Hola, parece que kindlegen ya no esta descargable desde amazon.
Hay algun link para descargar el binario?

ModuleNotFoundError: No module named 'kindlecomicconverter'

Cuando intento descargar algún capítulo con formato epub me aparece el siguiente error:

Traceback (most recent call last):
File "manga.py", line 291, in
from kindlecomicconverter.comic2ebook import main as manga2ebook
ModuleNotFoundError: No module named 'kindlecomicconverter'

Cuando lo intento descargar en PDF me aparece otro error:

Traceback (most recent call last):
File "manga.py", line 267, in
import img2pdf
ModuleNotFoundError: No module named 'img2pdf'

Fails when cache

Ok, there is an error on cap 493, but im not targeting it

python3 manga.py naruto --chapters 390..399 --format MOBI --rotate --single --cache

Searching naruto...
Converting to MOBI...
Naruto 390-399
Preparing source images...
Checking images...
Image file ./manga/Naruto/493/20.png is corrupted. Error: cannot identify image file '/tmp/KCC-1z339j1x/OEBPS/Images/493/20.png'

No instala 'kindlecomicconverter'

buenas amigo, primero que nada muy buena app, lo quise instalar hace poco y me encontre que no esta instalando la depedencia, pkg_resources.DistributionNotFound: The 'kindlecomicconverter' distribution was not found and is required by the application

'float' object cannot be interpreted as an integer

File "....\manga.py", line 280, in cache_convert
manga2ebook(argv)

File ".....\AppData\Roaming\Python\Python310\site-packages\kindlecomicconverter\comic2ebook.py", line 74, in main
makeBook(source)

File "....\AppData\Roaming\Python\Python310\site-packages\kindlecomicconverter\comic2ebook.py", line 1089, in makeBook
imgDirectoryProcessing(os.path.join(path, "OEBPS", "Images"))
File "....\AppData\Roaming\Python\Python310\site-packages\kindlecomicconverter\comic2ebook.py", line 526, in imgDirectoryProcessing raise RuntimeError("One of workers crashed. Cause: " + workerOutput[0][0], workerOutput[0][1])
("One of workers crashed. Cause: 'float' object cannot be interpreted as an integer"
, ' File "....\AppData\Roaming\Python\Python310\site-packages\kindlecomicconverter\comic2ebook.py", line 563, in imgFileProcessing\n img.autocontrastImage()\n File "...\AppData\Roaming\Python\Python310\site-packages\kindlecomicconverter\image.py", line 258, in autocontrastImage\n self.image = ImageOps.autocontrast(Image.eval(self.image, lambda a: 255 * (a / 255.) ** gamma))\n File "...\AppData\Roaming\Python\Python310\site-packages\PIL\Image.py", line 3107, in eval\n return image.point(args[0])\n File "...\AppData\Roaming\Python\Python310\site-packages\PIL\Image.py", line 1680, in point\n return self._new(self.im.point(lut, mode))\n')

id PageList cannot be found

Hi.

I tried to download a Manga using the repository. After clone and install dependencies and read the instructions I did:

python3.6 manga.py --format png --chapters "last" Berserk

and the script crash printing the website and I got the following error:

Traceback (most recent call last):
  File "manga.py", line 246, in <module>
    pages = html.find(id='PageList').find_all(True, recursive=False)
AttributeError: 'NoneType' object has no attribute 'find_all'

It seems that in the web code is not that id (I look for it in the complete trace), but using Firefox appear.
How could I fix this?

ModuleNotFound error: No module called "requests"

Hello everyone. When i try to open this program by typing "phyton manga.py" or "phyton manga.py -h" it shows me a message saying:

Traceback (most recent call last):
File "manga.py", line 8, in
from requests import get, post
ModuleNotFoundError: No module named 'requests'

I dont know what i´m doing wrong.
Thank you in advance :(

"Not Found" a tots els manga que cerc.

Hola,
He estat usant el teu codi durant uns mesos i funcionava perfecte, però fa una setmana cada vegada que cerc un manga per descarregar-lo hem surt el missatge de Not Found, no he canviat res del codi, i no se que fer perque no sé de programació, creus que podries ajudar-me?

He adjuntat una imatge del terminal.

Gràcies.
Captura de pantalla 2020-01-14 a las 11 41 59

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.