-
-
Notifications
You must be signed in to change notification settings - Fork 242
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
FEAT: Scraper : New features & improvements #1110
Conversation
by: t0b10-t3nm4 <[email protected]>
- The script now make 5 retries when api reaches "maximum threads" - Implement CRC search in screenscraper (as fallback when the rom name doesn't give results)
Adding readline binary to get text from Terminal application. It allows to move the cursor in Terminal app without displaying special characters. Usage: readline [-h] [-m "prompt"] -h Show this help message -m "prompt" Specify a custom prompt message This will create /tmp/readline.txt with the entered value by the user. #include <stdio.h> #include <stdlib.h> #include <string.h> #include "linenoise.h" void printHelp() { printf("Usage: readline [-h] [-m \"prompt\"]\n"); printf(" -h Show this help message\n"); printf(" -m \"prompt\" Specify a custom prompt message\n"); printf("\nThis will create /tmp/readline.txt with the entered value by the user."); printf("\nBy Schmurtz (Onion Team)\n\n"); } int main(int argc, char *argv[]) { char *prompt = "Enter text: "; // Default prompt message for (int i = 1; i < argc; i++) { if (strcmp(argv[i], "-h") == 0) { printHelp(); return 0; } else if (strcmp(argv[i], "-m") == 0 && i + 1 < argc) { prompt = argv[i + 1]; // Use the custom prompt message } } char *line = linenoise(prompt); if (line != NULL) { // Print the entered text with a newline printf("%s\n", line); // Generate the shell script content FILE *scriptFile = fopen("/tmp/readline.txt", "w"); if (scriptFile != NULL) { fprintf(scriptFile, "%s", line); fclose(scriptFile); } linenoiseFree(line); } return 0; }
Using readline binary instead of read -p it allows to move the cursor without writing strange characters.
- Implemented Media Type selection in the configuration (it applies to every scrapers) - Implemented region selection in the configuration (it applies to SS and LB) (enormous work to know the used regions on each scraper, put all these in a database and create fallback for each : for example search order fr -> eu -> world ...) - Improved the search by CRC for screenscraper (use xcrc, skip when the file is too big) it has required some discussion with screenscraper because their documentation is wrong on this feature. - Improved the input of text thanks to readline binary created myself (it allows to move the cursor without displaying special characters) - Added a new option in screenscraper settings to easily check credentials and have account state. It serves several purposes : _ during update : will add missing keys with default value _ missing config file : will create it with default value. _ corrupted config file : will re-create it with default value. - Many fixes and optimizations Co-authored-by: t0b10-t3nm4 <[email protected]> Co-authored-by: Schmurtz <[email protected]>
So far done 3D box art in UK region for a large folder Multiple sizes of rom collections (some over 800) All seems good Edit: One output:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Have tested very much as a user, but it works great
(big work to determine the used regions on each scraper, put all these in a database and create fallback for each : for example search order fr -> eu -> world ...)
_ during update : will add missing keys with default value
_ missing config file : will create it with default value.
_ corrupted config file : will re-create it with default value.
by: schmurtzm
with the collaboration of t0b10-t3nm4