Coder Social home page Coder Social logo

fkulibrary's Introduction

F! Library

Scrape metadata from FAKKU or Panda and build your own local FAKKU library with Komga or any other CMS that supports ComicInfo.xml metadata.

Example results
<ComicInfo xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <Title>Sekigahara-san Has Something to Hide</Title>
  <Series>Sekigahara-san Has Something to Hide</Series>
  <Number>1</Number>
  <Summary>Thrilling and agonizing! The start of a rich girl series!</Summary>
  <Year>2020</Year>
  <Month>01</Month>
  <Writer>Tsukako</Writer>
  <Publisher>FAKKU</Publisher>
  <Tags>Bunny Girl, Busty, Cosplay, Deepthroat, Fishnets, Hentai, Light Hair, No Sex, Ojousama, Paizuri, Stockings, Story Arc, Uncensored</Tags>
  <Genre>Original Work</Genre>
  <Web>https://www.fakku.net/hentai/sekigahara-san-has-something-to-hide-english</Web>
  <LanguageISO>en</LanguageISO>
  <Manga>Yes</Manga>
  <SeriesGroup>Comic Kairakuten BEAST 2020-01</SeriesGroup>
  <AgeRating>Adults Only 18+</AgeRating>
</ComicInfo>

Image of the series "Sekigahara-san Has Something to Hide" in Komga.

Quick links



Getting Started

Prerequisites

Accepted archive filenames examples

  • [Circle (Artist)] Title (Comic XXX) [Publisher] [etc.].ext
  • [Artist] Title (Comic XXX).ext
  • Title (Comic XXX).ext
  • Title.ext

Supported filetypes

  • .zip
  • .cbz
  • .rar
  • .cbr
  • .7z
  • .cb7



Setup

Clone the repository

  • Clone the repository by downloading and extracting the files to a directory of your choice or with Git.
git clone https://github.com/shrublet/FKULibrary.git

Setup Selenium WebDriver (optional)

  • It's highly recommneded to setup and download Selenium as well to access publicly blocked pages. Download the WebDriver for your browser and the Selenium for C# package (linked below). Extract the WebDriver executable (for Google Chrome, this would be chromedriver.exe) and WebDriver.dll from the raw .nupkg package to the root of your extracted repository (i.e. .\fakku-meta-scraper-main).

    • ⚠️ The WebDriver.dll is packaged inside .nupkg file under .\lib\net48\ and can be opened via any file archiver. Most Windows PCs should have .NET 4.8, so this is the recommended library. If the WebDriver isn't working as expected, ensure the version matches with your browser or try updating your browser/downgrading the WebDriver.

    • Browser WebDriver executables 1

    • Selenium WebDriver for C#

Import the module

  • You will need to do this every time you close your PowerShell window unless you add the module to your PowerShell module PATH. Ensure that your PowerShell window is opened in the correct directory.
cd "C:\path\to\extracted\repository"
Import-Module .\Fakku-Library.psm1



Usage

Set metadata for archive(s)

Set-FakkuMetadata
Available parameters

-FilePath -Recurse -Url -UrlFile -InputFile -Sleep -Destination -Safe -Headless -Incognito -Log -LogPath

Retrieve and write metadata to the console

Show-FakkuMetadata
Available parameters

-Name -Url -Safe -Headless -Incognito

Return corresponding FAKKU links for archive(s)

Get-FakkuLinks
Available parameters

-FilePath -Name -Recurse



Examples

Set metadata for an archive

Set-FakkuMetadata -FilePath "C:\path\to\file.zip"

Set metadata for archives in specified directory

Set-FakkuMetadata -FilePath "C:\path\to\files"

Set metadata for an archive from a FAKKU link

Set-FakkuMetadata "C:\path\to\file.zip" -Url "https://www.fakku.net/hentai/Bare-Girl-english"

Set metadata for a list of archives

Set-FakkuMetadata -InputFile "C:\path\to\list\of\archives.txt"

Set metadata for archives in specified directory with a list of URLs

Set-FakkuMetadata "C:\path\to\files" -UrlFile "C:\path\to\list\of\urls.txt"

Get and display metadata from a FAKKU link

Show-FakkuMetadata https://www.fakku.net/hentai/Bare-Girl-english

Get and display metadata from a title

Show-FakkuMetadata "Bare Girl"



Parameter Descriptions

-FilePath

Archive or directory or archives to set metadata for

-Name

Work title to search FAKKU/Panda for

-Recurse

Whether to recursively search the directory for archives (default: False)

-Url

FAKKU/Panda URL to pull metadata from

-Sleep

Time to sleep between scrapes (default: 0)

-InputFile

Text file with directories to tag

-UrlFile

Text file with FAKKU/Panda URLs to use for tagging (compatible with both -FilePath and -InputFile)

-Destination

Path to move completed archives to (default: None)

-Safe

Force the use of Selenium to scrape metadata to avoid edge-case metadata issues (default: False)

-Headless

Launches browser in headless mode (default: True)

-Incognito

Launches browser in incognito/private mode (default: False)

-Log

If logs should be written (default: False)

-LogPath

Path to save log to (default: .\fakku_library.log)

Footnotes

  1. Currently only supports Google Chrome, Microsoft Edge, and Firefox.

fkulibrary's People

Contributors

jeffvli avatar jvlflame avatar shrublet avatar

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.