Documentation ¶
Index ¶
- Constants
- func ConvertToPDF(name string, number string)
- func CreateFolder(url string) string
- func DownloadFile(url string, name string, number string)
- func GetContent(url string) string
- func GetFile(url string, dir string) error
- func GetLinks(content string) []string
- func ListFiles(dir string) []fs.FileInfo
- func Message(str string, level string)
- func RemoveFile(dir string, name string)
Constants ¶
const ( ColorReset string = "\033[0m" ColorRed string = "\033[31m" ColorGreen string = "\033[32m" ColorYellow string = "\033[33m" ColorBlue string = "\033[34m" ColorPurple string = "\033[35m" ColorCyan string = "\033[36m" ColorGray string = "\033[37m" ColorWhite string = "\033[97m" )
Colors ... Lists all the colors used in the application.
const ( MetadataName string = "Oh My Scan" MetadataUsage string = "Download locally your favorite french manga scans." MetadataDownload string = "Download your favorite manga from scan-op.cc." MetadataMerge string = "Merge uploaded images into a single PDF file." MetadataFlagsName string = "Enter the name of the desired manga." MetadataFlagsNumber string = "Enter the volume number of the desired manga." MetadataFlagsMerge string = "Merge directly the manga you just downloaded." )
Metadata ... List of metadatas used in the application.
const ( PlatformName string = "scan-op" PlatformURL string = "https://scan-op.cc/manga/" )
Platforms ... List of the name and link of the platform used in this application.
const (
ErrorArgumentsEmpty string = "You need to specify the the manga's name and the volume's number."
)
Errors ... List of recurring errors used in this application.
const Folder string = "downloads/"
Folder ... Location of the download directory.
Variables ¶
This section is empty.
Functions ¶
func ConvertToPDF ¶
ConvertToPDF ... Function that allows you to convert multiple images into a single PDF.
- name(string): Name of the manga to convert.
- number(string): Volume number to convert.
func CreateFolder ¶
CreateFolder ... Function that allows you to create a folder.
- name(string): Name of the folder to be created.
func DownloadFile ¶
DownloadFile ... Function that allows you to download documents online.
- url(string): URL of the HTML page.
- name(string): Name of the manga to download.
- number(string): Volume number to download.
func GetContent ¶
GetContent ... Function that allows you to retrieve all the content of an HTML page.
- url(string): URL of the HTML page.
func GetFile ¶
GetFile ... Function that allows you to recover files from links.
- url(string): URL of the HTML page.
- dir(string): Folder where the images will be downloaded.
func GetLinks ¶
GetLinks ... Function that allows you to list all the image links present in an HTML document.
- content(string): Content of the html page to retrieve image links.
func ListFiles ¶
ListFiles ... Function that allows you to list all the files in a folder.
- dir(string): Name of the folder to list.
func Message ¶
Message ... Function that allows you to display many messages, such as errors, etc.
- str(string): Content of the message.
- level(string): Alert level of the message.
func RemoveFile ¶
RemoveFile ... Function that allows you to delete a file.
- dir(string): Name of the folder where the files to be deleted are located.
- name(string): Name of the file to be deleted.
Types ¶
This section is empty.