Page 1 of 1
Using a Symbolic Link to Make Accessing ROM Set Easier From the Super Gameboy Core
Posted: Sat Aug 13, 2022 11:28 pm
by mineral55
For the less tech savvy among us that haven't thought about using a symbolic link in order to reach their gameboy roms automatically instead of having to go up a directory to access the GAMEBOY folder each time when using the Super Gameboy core, here is a short guide for you:
If you keep your Super Gameboy sfc files in your SGB folder transfer them to the GAMEBOY folder within /media/fat/games/GAMEBOY/ and empty its contents and delete it (if you do this now you may skip step 5).
Plug in a keyboard into your MiSTer
Press the F9 key
Enter root as your username and 1 as the password
Delete the SGB folder if you haven't already
it will complain if you have files in there in which case (making certain there's nothing in SGB that you care to save):
Code: Select all
rm /media/fat/games/SGB/*
rmdir /media/fat/games/SGB/
Enter the command
Code: Select all
ln -s /media/fat/games/GAMEBOY/ /media/fat/games/SGB
then enter:
and reset your MiSTer
Voila! Your SGB folder is now a soft link to the GAMEBOY folder and you can access your romlist directly from the SGB core without going through extra key presses now!
I think you can do this remotely with curl but I don't know how Can someone post how to in this thread?
Re: Using a Symbolic Link to Make Accessing ROM Set Easier From the Super Gameboy Core
Posted: Sun Aug 14, 2022 6:08 am
by rafael
I think this should do the trick (please replace the variable with the IP of your MiSTer on your local network)
Code: Select all
ssh root@$MISTER_IP_ADDRESS ln -s /media/fat/games/GAMEBOY/ /media/fat/games/SGB
Re: Using a Symbolic Link to Make Accessing ROM Set Easier From the Super Gameboy Core
Posted: Sun Aug 14, 2022 3:00 pm
by rhester72
I'm still not sure how on earth you're symlinking on a filesystem that doesn't support soft links.
Re: Using a Symbolic Link to Make Accessing ROM Set Easier From the Super Gameboy Core
Posted: Sun Aug 14, 2022 3:40 pm
by rafael
rhester72 wrote: ↑Sun Aug 14, 2022 3:00 pm
I'm still not sure how on earth you're symlinking on a filesystem that doesn't support soft links.
Check this post out for more information
viewtopic.php?t=322
Re: Using a Symbolic Link to Make Accessing ROM Set Easier From the Super Gameboy Core
Posted: Sun Aug 14, 2022 9:31 pm
by mineral55
rafael wrote: ↑Sun Aug 14, 2022 3:40 pm
rhester72 wrote: ↑Sun Aug 14, 2022 3:00 pm
I'm still not sure how on earth you're symlinking on a filesystem that doesn't support soft links.
Check this post out for more information
viewtopic.php?t=322
I can't seem to find much there other than symlinks work in MiSTer and I may have issues transferring to another device (links turn into text files?) so it's not a good idea to have a lot of them? Will this potentially break anything does anyone know?
Re: Using a Symbolic Link to Make Accessing ROM Set Easier From the Super Gameboy Core
Posted: Sun Aug 14, 2022 10:43 pm
by pgimeno
If a symbolic link becomes a text file, you can always redo it. The only problem is knowing that it was a symlink to begin with.
My files are in another partition of the SD card, using ext4fs, and the "main" exFAT partition only has the Linux system, menu.rbf, the main MiSTer and MiSTer.ini, and the rest are symlinks to the other partition. Working like that for over a year now without problems, apart from case sensitivity issues in some cores due to ext4 being case sensitive, which were easy to fix, and a couple minor annoyances.
So I'd say it's pretty safe.
Re: Using a Symbolic Link to Make Accessing ROM Set Easier From the Super Gameboy Core
Posted: Mon Nov 21, 2022 5:51 am
by JayRockets
rafael wrote: ↑Sun Aug 14, 2022 6:08 am
I think this should do the trick (please replace the variable with the IP of your MiSTer on your local network)
Code: Select all
ssh root@$MISTER_IP_ADDRESS ln -s /media/fat/games/GAMEBOY/ /media/fat/games/SGB
where do I enter this? it isn't working in command prompt
edit: nevermind. I must have uninstalled OpenSSHClient. it worked.
Re: Using a Symbolic Link to Make Accessing ROM Set Easier From the Super Gameboy Core
Posted: Sun Jan 22, 2023 12:15 am
by ItalianGrandma
For anyone using WinSCP, you can just right click inside the directory you want to add the link to and add a new link. Then you specify the path it points to and you’re all set.
Re: Using a Symbolic Link to Make Accessing ROM Set Easier From the Super Gameboy Core
Posted: Thu Jan 26, 2023 9:42 pm
by Malor
A better way of doing this, which didn't become mainstream on the Mister until after this thread was created, is to use favorites.sh. You can get it by using update_all, and turning on the Wizzo extension scripts.
Once you've got it, just run that script and point it at the ROM you want. Then name it whatever you like, and it will create and save it as an "mgl" file. This is a text file that tells the menu what core to launch and what ROM to use. It functions rather like a symlink, but doesn't depend on any filesystem features. It should work to load any core and ROM that the main menu can find, including any filesystem type or network share.
If you can mount a location into the directory tree somewhere, an MGL should be able to load ROMs from there.
Re: Using a Symbolic Link to Make Accessing ROM Set Easier From the Super Gameboy Core
Posted: Sat Feb 04, 2023 12:33 pm
by KOLWE-X
Thanks mineral55,
works good so far. But unfortunatley I can't use my saves in the GB core and/or in the SGB core. If tried it with:
ln -s /media/fat/saves/GAMEBOY/ /media/fat/saves/SGB
But that doesn't work
Is there any way that both cores can share the same save file?
Thanks again for all the good work here.
Best regards,
kolwe-x
Re: Using a Symbolic Link to Make Accessing ROM Set Easier From the Super Gameboy Core
Posted: Wed Feb 08, 2023 6:21 am
by mineral55
No problem, it really wasn't any work on my part. I just remembered that MiSTer runs on linux and it might be possible to make links and somehow it is!
I'm guessing SGB doesn't handle saves the same as GAMEBOY? I guess they should in theory handle saves the same. Does anyone know?
Re: Using a Symbolic Link to Make Accessing ROM Set Easier From the Super Gameboy Core
Posted: Wed Feb 08, 2023 9:00 pm
by KOLWE-X
Hi mineral55,
I've tested it and you can use the saves from GB in the SGB core or the other way around. But I have to copy the save files manually.
Hopefully someone will have a solution in future. That would be very nice
Re: Using a Symbolic Link to Make Accessing ROM Set Easier From the Super Gameboy Core
Posted: Thu Feb 09, 2023 11:14 am
by mineral55
Oh you just forgot to empty SGB you silly goose! You can't have a symbolic link exist with the folder it's linking away from lol. It should recognize your GAMEBOY saves once you've backed up and emptied SGB and run ln -s /media/fat/saves/GAMEBOY/ /media/fat/saves/SGB
Re: Using a Symbolic Link to Make Accessing ROM Set Easier From the Super Gameboy Core
Posted: Wed Feb 15, 2023 6:56 pm
by KOLWE-X
Nope, that doesn't work.
I've got the GAMEBOY directory in my SGB Save directory. So the system can't see the save files.
It should see the saves directly inside the SGB save folder, but how?
Re: Using a Symbolic Link to Make Accessing ROM Set Easier From the Super Gameboy Core
Posted: Mon Feb 20, 2023 6:05 pm
by mineral55
what does ls -l output from /media/fat/saves/?
Re: Using a Symbolic Link to Make Accessing ROM Set Easier From the Super Gameboy Core
Posted: Sun Feb 26, 2023 10:22 am
by KOLWE-X
Hi,
sorry for my late response, but I was busy the last days.
As you can see in the screenshot from Filezilla, the command
ln -s /media/fat/saves/GAMEBOY/ /media/fat/saves/SGB
does this.
So the MiSTer Core of SGB can't see the saves, because it's searching the SGB saves file, but not the GAMEBOY file.
Is there any possible command, so the saves from GB will show up in the SGB folder?
Thanks again for all help.
Re: Using a Symbolic Link to Make Accessing ROM Set Easier From the Super Gameboy Core
Posted: Sun Feb 26, 2023 12:08 pm
by mineral55
That's not the output of ls -l. I suspect that your link didn't take or you made some kind of typo which ls -l would reveal. I'm assuming you didn't SSL into your MiSTer so you can't copy and paste the output? Since you're on windows I'm not sure what the best app for it is so I can't be of help there. I personally tested symlinking saves/SGB pointing to saves/GAMEBOY and it worked fine with the GAMEBOY core using its folder as always and the SGB core now referring to saves/GAMEBOY (via the symlink named SGB). I believe you skipped a step or did something wrong
Re: Using a Symbolic Link to Make Accessing ROM Set Easier From the Super Gameboy Core
Posted: Sun Feb 26, 2023 12:50 pm
by KOLWE-X
I don't know what to do else? It's the same procedure as for the games, like your first post, but with the saves it doesn't work.
I've use Putty to get into the root of my MiSTer, but it's always doing this, like in the picture I#ve uploaded.
So, nobody seems to have this problem, because no one else response to our posts. I can live with this issue, so it's ok. I give up.
Re: Using a Symbolic Link to Make Accessing ROM Set Easier From the Super Gameboy Core
Posted: Sun Feb 26, 2023 1:56 pm
by Tulius
I wanted to do the same for NeoGeo CD core to search for .CHDs in a new NeoGeocd game folder instead of together with MVS/AES rom folders, because they are two different consoles.
Re: Using a Symbolic Link to Make Accessing ROM Set Easier From the Super Gameboy Core
Posted: Sun Feb 26, 2023 6:10 pm
by mineral55
KOLWE-X wrote: ↑Sun Feb 26, 2023 12:50 pm
I don't know what to do elese? It's the same procedure as for the games, like your first post, but with the saves it doesn't work.
I've use Putty to get into the root of my MiSTer, but it's always doing this, like in the picture I#ve uploaded.
So, nobody seems to have this problem, because no one else response to our posts. I can live with this issue, so it's ok. I give up.
Why give up so easy?
This is what I did again to test and my output with ls -l
Code: Select all
/media/fat/saves# ln -s ../saves/GAMEBOY/ ../saves/SGB
/media/fat/saves# ls -l
total 2432
drwxr-xr-x 2 root root 131072 Feb 8 10:21 ATARI7800
drwxr-xr-x 2 root root 131072 Jun 20 2022 AtariLynx
drwxr-xr-x 2 root root 131072 Nov 24 20:08 GAMEBOY
drwxr-xr-x 2 root root 131072 Sep 25 22:45 GAMEBOY2P
drwxr-xr-x 2 root root 131072 Feb 15 15:24 GBA
drwxr-xr-x 2 root root 131072 Sep 25 03:50 GBA2P
drwxr-xr-x 2 root root 131072 Dec 3 18:19 GBC
drwxr-xr-x 2 root root 131072 Feb 14 03:52 Genesis
drwxr-xr-x 2 root root 131072 Jan 11 04:34 MegaCD
drwxr-xr-x 2 root root 131072 Jan 21 20:54 NEOGEO
drwxr-xr-x 2 root root 131072 Feb 5 04:46 NES
drwxr-xr-x 2 root root 131072 Sep 13 21:32 PokemonMini
drwxr-xr-x 2 root root 131072 Feb 21 08:19 PSX
lrwxr-xr-x 1 root root 17 Feb 26 13:00 SGB -> ../saves/GAMEBOY/
drwxr-xr-x 2 root root 131072 Feb 9 06:10 SGB_Backup
drwxr-xr-x 2 root root 131072 Sep 28 14:01 SMS
drwxr-xr-x 2 root root 131072 Feb 20 05:19 SNES
drwxr-xr-x 2 root root 131072 Dec 26 08:39 TGFX16
drwxr-xr-x 2 root root 131072 Jul 28 2022 WonderSwan
My original SGB folder was changed to SGB_Backup (since I can't create a symlink when a folder of the same name exists as aforementioned) and to test my symlink I go into the SGB core and boot up Metroid and load up my first save. It works! Symlinks work perfectly fine with saves on MiSTer. You're doing something wrong
Re: Using a Symbolic Link to Make Accessing ROM Set Easier From the Super Gameboy Core
Posted: Wed May 31, 2023 1:18 am
by maze
Thanks for this thread. I've got a bunch of symlinks set up now, which is great.
Is it safe to link from /saves/GBC to /saves/GAMEBOY/? I assume so, but I'm not sure if there would be any conflicts.