{"id":15546744,"url":"https://github.com/yinyanfr/comic-dl","last_synced_at":"2025-04-23T18:10:51.169Z","repository":{"id":142236545,"uuid":"613016876","full_name":"yinyanfr/comic-dl","owner":"yinyanfr","description":"Yet another manga / comic downloader","archived":false,"fork":false,"pushed_at":"2023-07-30T21:57:36.000Z","size":7728,"stargazers_count":20,"open_issues_count":5,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-11T15:42:42.479Z","etag":null,"topics":["comic","comic-downloader","copymanga","downloader","ganma","manga","manga-downloader","scraper","zerobyw"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/yinyanfr.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-03-12T16:48:06.000Z","updated_at":"2025-02-19T00:14:27.000Z","dependencies_parsed_at":"2024-10-21T20:21:51.566Z","dependency_job_id":null,"html_url":"https://github.com/yinyanfr/comic-dl","commit_stats":{"total_commits":32,"total_committers":1,"mean_commits":32.0,"dds":0.0,"last_synced_commit":"92e16118af673ba7fa6bc410a2152c871601dd19"},"previous_names":["yinyanfr/zerobyw-dl"],"tags_count":16,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yinyanfr%2Fcomic-dl","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yinyanfr%2Fcomic-dl/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yinyanfr%2Fcomic-dl/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yinyanfr%2Fcomic-dl/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/yinyanfr","download_url":"https://codeload.github.com/yinyanfr/comic-dl/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250242575,"owners_count":21398154,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["comic","comic-downloader","copymanga","downloader","ganma","manga","manga-downloader","scraper","zerobyw"],"created_at":"2024-10-02T13:04:11.054Z","updated_at":"2025-04-23T18:10:51.153Z","avatar_url":"https://github.com/yinyanfr.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# comic-dl\n\n[![npm](https://img.shields.io/npm/v/comic-dl.svg?style=flat-square)](https://www.npmjs.com/package/comic-dl)\n![license](https://img.shields.io/npm/l/comic-dl.svg?style=flat-square)\n![size](https://img.shields.io/github/repo-size/yinyanfr/comic-dl?style=flat-square)\n[![GitHub release](https://img.shields.io/github/release/yinyanfr/comic-dl.svg?style=flat-square)](https://github.com/yinyanfr/comic-dl/releases/latest)\n\nAs of the version 2, **`zerobyw-dl` has become `comic-dl`.** Now this library is for generic uses.\n\nLooking for `zerobyw-dl`? [Check here](https://github.com/yinyanfr/comic-dl/tree/v1).\n\nThis library is not for browsers.\n\nPlease help me translate the documents, thanks.\n\n## :star2: Features\n\n- Very low memory usage\n- CLI tools\n- Supports multiple sites (More on the road)\n- Supports shorthand URLs\n- Download as ZIP/CBZ, or just a folder of pictures\n- Downloading progress watch\n- Detects downloaded chapters\n- Sync / Update downloaded chapters\n- Generates [ComicInfo.xml](https://anansi-project.github.io/docs/comicinfo/intro)\n\n## :rainbow: [Site List](docs/user/sites.md)\n\n- [Zerobyw](https://zerobyw.github.io/)\n- [Copymanga](https://www.copymanga.site/)\n- [Ganma](https://ganma.jp/)\n\n## :framed_picture: Gallery\n\n### List of chapters\n\n![List of chapters](asset/ls.png)\n\n### Downloading\n\n![Downloading](asset/dl.png)\n\n## :green_book: Quick Start\n\n### Stable\n\nYou need Node.js (LTS or the current version) to run this project.\n\n```bash\nnpm i comic-dl\n# or\n# CLI\nnpx comic-dl help\n```\n\n### Nightly\n\n```bash\nnpm i yinyanfr/comic-dl\n# or\ngit clone https://github.com/yinyanfr/comic-dl.git\ncd comic-dl\nnpm i\nnpx . help\n```\n\n## :wrench: Cli\n\n```\nUsage: comic-dl [options] [command]\n\nCommands:\n  chapter, c, ch    Download images from one chapter.\n  download, d, dl   Download chapters from a manga serie.\n  generate, g, gen  Generate template for your module.\n  help              Display help\n  list, l, ls       List all chapters of a manga serie.\n  version           Display version\n\nOptions:\n  -a, --archive           Optional: Output zip or cbz archive grouped by chapters.\n  -A, --auth              Optional: A string that contains token or cookie.\n  -b, --batch             Optional: Set the number or images to be downloaded simultaneously, default to 1.\n  -C, --chapters          Optional: Only downloading given list of chapters, example: -C 1,2,4,7\n  -c, --cookie            Optional (but recommanded): Provide the path to a text file that contains your cookie.\n  -F, --format            Optional: the format of downloaded picture, depending on the modules, example: webp / jpg.\n  -f, --from              Optional: Starting chapter when downloading a serie, default to 0.\n  -g, --group             Optional: For sites that provides series in groups, please refer to the site info docs, default to default.\n  -H, --help              Output usage information\n  -h, --history           Optional: (Experimental) Add the serie url to a given text file when using the `download` command, its value is default to a `history.txt` file under the same path of `--output`.\n  -I, --indexed-chapters  Optional: Add index to the folder / archive file name of chapters.\n  -i, --info              Optional: Generate ComicInfo.xml.\n  -l, --list              Optional: (Experimental) The path to a text file that contains a list of URLs.\n  -M, --max-title-length  Optional: restrict the length of title as the folder name.\n  -m, --module            Optional: Specify the module (site) name. Will attempt to detect module by url if not set.\n  -n, --name              Optional: Proride the serie title and override the folder name.\n  -o, --output            Optional: The path where downloaded files are saved (default to .), setting this flag when using list will save a ComicInfo.xml to the path.\n  -O, --override          Optional: overrides downloaded chapters.\n  -p, --presets           Optional: loading a JSON file of site presets.\n  -r, --retry             Optional: Automatically re-download chapters with failed images.\n  -S, --shorthand-url     Optional: The shorthand url, please refer to the module docs.\n  -s, --slience           Optional: Silence the console output, including the confirm prompt.\n  -T, --timeout           Optional: Override the default 10s request timeout.\n  -t, --to                Optional: Ending chapter when downloading a serie, defaults to chapter.length - 1.\n  -u, --url               Optional: The url to the serie or the chapter.\n  -v, --verbose           Optional: Display detailed error message, overrides silence.\n  -V, --version           Output the version number\n  -y, --yes               Optional: Skipping confirmation prompt when downloading series.\n  -z, --zip-level         Optional: zip level for archive, default to 5.\n\nExamples:\n  - Download a serie from its 10th chapter to 20th chapter to the given destination, 10 images at a time, output zip archives with ComicInfo.xml by chapter, retry if a chapter is not properly downloaded.\n  $ npx comic-dl dl -c cookie.txt -f 10 -t 20 -o ~/Download/manga -a zip -r -i -b 10 -u serie_url\n\n  - Download chapter index 0, 4, 12 from a serie, overriding downloaded files.\n  $ npx comic-dl dl -c cookie.txt -o ~/Download/manga -i -O -u serie_url -c 0,4,12\n\n  - Download from the group tankobon from a site that provide series in different groups.\n  $ npx comic-dl -u serie_url -g tankobon\n\n  - Download a serie with presets\n  $ npx comic-dl -p presets.json -u serie_url\n\n  - List all chapters of the given serie.\n  $ npx comic-dl ls -u serie_url\n\n  - Using shorthand URLs.\n  $ npx comic-dl -m zerobyw -S 12345\n\n  - Download a chapter named Chapter1 to current path.\n  $ npx comic-dl ch -n Chapter1 -u chapter_url -c cookie.txt\n\n  - Generate a new module named mySite.\n  $ npx . gen --module mySite\n\n  - Generate a presets json.\n  $ npx . gen --presets \u003e presets.json\n```\n\nYou can now use presets to reduce the number of flags, [check here](docs/user/presets.md) for details.\n\n## :book: Library\n\n### Initializing downloader\n\n```typescript\nimport ZeroBywDownloader from 'zerobyw-dl';\n\n// Path for downloaded files\nconst destination = '~/Download/zerobyw';\n// Configs\nconst configs = {\n  // Get your cookie from the network inspector of your browser\n  // Optional but highly recommanded, as ZeroByw partially blocks content for non-paid users\n  cookie: 'your_cookie',\n  // Request timeout in ms (Optional: default to 10 seconds)\n  timeout: 10000,\n  // Silencing console output (Optional)\n  silence: false,\n  // numbers of images to be downloaded simultaneously (Optional: default to 10)\n  batchSize: 10,\n  // Display detailed error message, will override silence (Optional)\n  verbose: false,\n  // Output zip or cbz archives grouped by chapters (Optional)\n  archive: 'zip',\n  // Additional headers for HTTP Requests (Using axios under the hood) (Optional)\n  headers: {},\n  // Restrict the length of title's length, in case your file system has such limitation (Optional: default to undefined)\n  maxTitleLength: 30,\n  // Zip level for archives (Optional: default to 5)\n  zipLevel: 5,\n  // Format of downloaded image, (Optional: depending on the modules, normally default to webp or jpg)\n  format: 'webp',\n  // Add index to the folder / archive file name of chapters (Optional)\n  indexedChapters: false,\n}; // Optional\n\nconst downloader = new ZeroBywDownloader(destination, configs);\n```\n\n### :scroll: Getting serie info\n\n```typescript\nconst options = {\n  output: 'output_path', // Optional: Set this to write a ComicInfo.xml to the path, use true to output to the inherited destination folder\n  // By default, the file is downloaded to destination/serie_title/ComicInfo.xml\n  rename: 'serie_title', // Optional: Override the serie title folder name\n  filename: 'ComicInfo.xml', // Optional: Overrides the default file name\n};\n\nconst info = await downloader.getSerieInfo('serie_url');\n// info\n// {\n//   title: \"Serie Title\",\n//   chapters: [{\n//     index: 0,\n//     name: \"Chapter Name\",\n//     uri: \"chapter_uri\", // without baseUrl\n//   }],\n//   info: {} // please refer to ComicInfo's Documentations\n// }\n```\n\n### :books: Downloading from a serie\n\n```typescript\nconst options = {\n  start: 10, // Optional: Starting chapter, inclusive, default to 0\n  end: 20, // Optional: Ending chapter, inclusive, default to the last (length - 1)\n  confirm: false, // Optional: Launch a console prompt asking for user's confirmation before starting downloading, default to false\n  rename: undefined, // Optional: Changing the folder name, default to undefined\n  retry: false, // Optional: Automatically re-download chapters with failed images.\n  info: true, // Optional: Generates ComicInfo.xml, default to **false**\n  chapters: undefined, // Optional: Array of chapter indexes to download, will download the entire serie if not provided\n  override: false, // Optional: Overriding downloaded chapters, default to false\n  group: 'default', // Optional: for sites like Copymanga, that offers series in multiple groups, default to default.\n  onProgress: progress =\u003e {\n    console.log(progress);\n  }, // Optional: Called when a chapter is downloaded or failed to do so\n}; // Optional\n\n// progress\n// {\n//   index: 0, // chapter index\n//   name: \"Chapter Name\",\n//   uri: \"chapter_uri\",\n//   status: \"completed\", // or \"failed\"\n//   failed: 1, // numbers of images failed to be downloaded\n//   // status is completed as the download queue is cleared, even with failed images.\n// }\n\n// Download all chapters from a serie\nawait downloader.downloadSerie('serie_url');\n\n// Download from the 10th to the 20th chapter (11 chapters in total)\nawait downloader.downloadSerie('serie_url', options);\n```\n\n### :bookmark: Downloading a chapter\n\n```typescript\nconst options = {\n  index: 0, // chapter index\n  title: 'Serie Title',\n  info: ComicInfo, // Optional: Generates ComicInfo.xml, please refer to ComicInfo's Documentations\n  override: false, // Optional: Overriding downloaded chapters, default to false\n  group: 'default', // Optional: for sites like Copymanga, that offers series in multiple groups, default to default.\n  onProgress: progress =\u003e {}, // Optional: Called when a chapter is downloaded or failed to do so, the same as in serie options\n}; // Optional\n\nawait downloader.downloadChapter(\n  'Chapter Name',\n  'chapter_url_with_base',\n  options,\n);\n```\n\n### :pencil2: Modify configs\n\n```typescript\n// change one config\ndownloader.setConfig('archive', 'cbz');\n// merge configs\ndownloader.setConfigs({ archive: 'cbz' }); // Will merge\n\n// get and set baseUrl\ndownloader.baseUrl = 'your_url';\n```\n\n## Development Guide\n\nDev Guide can be found [here](docs/README.md)\n\n## :information_source: Information\n\n- [ComicInfo.xml Documentations](https://anansi-project.github.io/docs/comicinfo/intro)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fyinyanfr%2Fcomic-dl","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fyinyanfr%2Fcomic-dl","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fyinyanfr%2Fcomic-dl/lists"}