Flexible/customisable launcher?

I’m looking for some sort of launcher that will allow me to specify a list of commands that a user can pick from. The aim is basically to be able to bypass MAME’s SDL interface on a very slow laptop.

For example, I might want to have users choose from the options on the left, that would then run the command on the right:

Purple Software Chess (Psion 3mx):  mame psion3mx -ssd1 ssd/chess.rom
Purple Software Chess (Psion 3a2):  mame psion3a2 -ssd1 ssd/chess.rom
Jumpy (Psion 3mx):                  mame psion3mx -ssd1 ssd/jumpy.rom
Jumpy (Siena):                      mame siena -ssd1 ssd/jumpysie.rom

I don’t mind if it’s graphical or ncurses/text-based.

Does anyone know of something that would do that? Otherwise I’m just going to create a load of bash scripts and put them on the desktop.

Hello. You can try using Yab.

Sorry, I case you are not familiar with Yab: is like Basic, but allow to create visual applications for Haiku. Is not suited for very complex applications, but to just create a frontend for a CLI command, is more than enough.

Yab:
Haiku Depot Server (haiku-os.org)

Yab-IDE
Haiku Depot Server (haiku-os.org)

1 Like

I like that idea. Better than messing around with bash scripts. I’ll give that a go this evening and see how I get on.

If you need some help ask here or visit our knowledge base besly for tutorials.

https://yab.besly.de/

as an example here my Alex4 Custom Maps to load and start the program with different levels

3 Likes

The quick and dirty way:

  • Put your scripts in /boot/home/config/non-packaged/bin. Create that directory if it doesn’t exist
  • [Optional] give your scripts some nice icons. If you dont feel like fighting with Icon-o-Matic, the old BeOS bitmap icons still work and there are thousands of them on BeShare.
  • Drag the scripts, one by one, into LaunchBox onto some empty buttons.

Alternatively, put the scripts in /boot/home/config/non-packaged/data/deskbar/menu/Applications (again, create that directory if it doesn’t exist) and they will automagically appear in your Deskbar’s Application menu. You can even create a MAME subdirectory for them if you like.

2 Likes

I recommend installing “hdialog” from HaikuDepot and do a bit of light scripting.
For the above example:

screenshot1

#!/bin/sh

opt1="Purple Software Chess (Psion 3mx)"
opt2="Purple Software Chess (Psion 3a2)"
opt3="Jumpy (Psion 3mx)"
opt4="Jumpy (Siena)"

answer=$(hdialog --title "MAME Games" --radio "Choose your game:" "$opt1" "$opt2" "$opt3" "$opt4")

case "$answer" in
	"$opt1")
		mame psion3mx -ssd1 ssd/chess.rom
		;;
	"$opt2")
		mame psion3a2 -ssd1 ssd/chess.rom
		;;
	"$opt3")
		mame psion3mx -ssd1 ssd/jumpy.rom
		;;
	"$opt4")
		mame siena -ssd1 ssd/jumpysie.rom
		;;
esac
6 Likes

Hi there.

In my opinión yab is the BEST option.

You can easy launchers using Yoshi

Im working in a Doom Launcher using Yoshi for my old pc (less than 1gb RAM)

screenshot18

Regards

5 Likes

Thank you to everyone for your help on this!

As I need this for tomorrow, I’ve used @humdinger’s hdialog solution. I ended up changing my method, creating one bash script for each game. They’re all based around a single script, but removing lines for machines that are incompatible with each game/app.

This has got the job done for now, so the laptop is ready to be used tomorrow.

However, I really like the idea of building a proper launcher using yab. I’ll be revisiting this in the near future.

Thanks, all!

10 Likes