Easy way of renaming Arcade roms?
-
Still not really getting how to do this. This is what I am doing, create folder called 'arcade' on c:
Copy 20 roms into 'arcade' folder. Copy scraper.exe to 'arcade' folder and then run in command prompt.
Get message 'It appears that thegamesdb isn't set up.'
-
@MikeLang You can try a source other TheGamesDB - Screenscraper.fr is probably considered best. Selph's scraper also needs to be run in MAME mode.
Try the command:
scraper -mame -mame_src ss
[EDIT: changed
-console-src
to-mame-src
] -
I typed 'scraper -mame -mame_src ss' in command prompt, just get a lot of text:
'flag provided but not defined: -mame_scr'
'-workers N'
'use N worker threads to process roms. (default 1)' -
@MikeLang said in Easy way of renaming Arcade roms?:
'flag provided but not defined: -mame_scr'
You said you entered
-mame_src
, yet the error says that you entered-mame_scr
(which would be wrong). Which one is the typo? -
Yep, that's what I've done, typed it wrong. It's working now but the gamelist.xml it generates has a synopsis of the game. I only want these bits:
<game>
<path>./Gamename.zip</path>
<name>Game Name</name>
</game>If that is possible. Really appreciating all the help.
-
EDIT: Ignore - please see @mitu's suggestion below.
@MikeLang You can use the
sed
command. This is a Linux command so it will have to be done on your Pi. I recommend that you use SSH so that the command can copied and pasted.First, use
cd
to change the directory to the one containing yourgamelist.xml
file, then run:sed '/<desc>\|<image>\|<rating>\|<releasedate>\|<developer>\|<publisher>\|<genre>\|<players>/d' gamelist.xml
This command will output to the terminal what the amended version of
gamelist.xml
will look like.If you're happy, then you can run the command below to commit the changes. This will overwrite your
gamelist.xml
file so good idea to keep a copy of the the original.sed -i '/<desc>\|<image>\|<rating>\|<releasedate>\|<developer>\|<publisher>\|<genre>\|<players>/d' gamelist.xml
The only concern is when the
<desc>
entry runs for more than one paragraph. Thesed
will not catch the second and subsequent paragraphs. There's probably a way to include these but I don't know of any.Extra paragraphs will make the XML file invalid as it will have unmatched tags and ES may not load. The extra paragraphs can be manually deleted in a text editor searching for
</desc>
string. -
@dudleydes It's easier with
xmlstarlet
:xmlstarlet ed -d '//game/desc' gamelist.xml
will delete all
desc
child nodes of thegame
node. Repeat for any other tag you'd like removed (favorite/image/video/etc.). -
@dudleydes said in Easy way of renaming Arcade roms?:
First, use
cd
to change the directory to the one containing yourgamelist.xml
file, then run:Already stuck, running putty, don't know how to change directory from 'pi@retropie:/ $' to:
\RETROPIE\configs\all\emulationstation\gamelists\arcade\gamelist
-
@mitu Thank you.
The command below will give a preview of amended
gamelist.xml
:xmlstarlet ed -d '//game/desc | //game/image | //game/releasedate | //game/rating | //game/developer | //game/publisher | //game/genre | //game/players' gamelist.xml
To write changes, add
--inplace
as below:xmlstarlet ed --inplace -d '//game/desc | //game/image | //game/releasedate | //game/rating | //game/developer | //game/publisher | //game/genre | //game/players' gamelist.xml
-
@MikeLang Try
cd /opt/retropie/configs/all/emulationstation/gamelists/arcade
After this command, run
ls
to checkgamelist.xml
is there. -
@MikeLang said in Easy way of renaming Arcade roms?:
Already stuck, running putty, don't know how to change directory from 'pi@retropie:/ $' to:
\RETROPIE\configs\all\emulationstation\gamelists\arcade\gamelist
Just an addition to @dudleydes' post: Windows uses backslashes (
\
) as directory dividers. The official Retropie image is running on Linux, which uses slashes as directory dividers (/
). -
@dudleydes said in Easy way of renaming Arcade roms?:
@mitu Thank you.
The command below will give a preview of amended
gamelist.xml
:xmlstarlet ed -d '//game/desc | //game/image | //game/releasedate | //game/rating | //game/developer | //game/publisher | //game/genre | //game/players' gamelist.xml
That's not giving me a full preview of gamelist, I'm getting something like this:
gamelist.xml:1697.16: xmlParseEntityRef: no name
<name>Game name</name>
^
gamelist.xml:1889.17: xmlParseEntityRef: no name
<name>Game name 2</name>
^The original command 'sed '/<desc>|<image>|<rating>|<releasedate>|<developer>|<publisher>|<genre>|<players>/d' gamelist.xml' is giving a fuller list but has entry run issues as you mentioned.
-
@MikeLang You'll have to be more specific, maybe you can upload your final gamelist.xml somewhere so we can check.
-
I know why I was getting that weird error now, it was related to having '&' in the name of a game. My example didn't help matters seeing as I didn't type '&'.
The list it generates still doesn't have the games I haven't picked, for example say the arcade rom folder has 300 games and the gamelist.xml file lists 200 roms. There's still 100 games that I have to manually pick in order for them to appear in the gamelist.xml file.
Thanks for all the help everyone I've learned a great deal from all your input.
Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.
Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.