Use any linux distribution inside your terminal. Enable both backward and forward compatibility with software and freedom to use whatever distribution you’re more comfortable with. Mirror available at: https://gitlab.com/89luca89/distrobox
When exporting the matching is pretty loose (surrounded by grabby .* regex) and when exporting something with a short name (1-3 characters) it can match a lot of things. Or in the case nothing is supplied it matches everything! (There should probably be a check whether exported_app is empty.)
I don't know what a good approach to the matching problem would be, since it's nice for users to be able to export something by a name guess that's only close enough. Maybe a confirmation dialog if it matches multiple desktop files?
I think it might be a good idea to have a flag to enable/disable searching of the Name= field.
Then when exporting by the command name you could use Exec=${exported_app} (notice the space at the end) to only match the provided command name. Since I'd assume someone using the command name would provide the full one.
PS the .* is not needed at the end.
https://github.com/89luca89/distrobox/blob/c05b6a43769bfa56d572a457f1420e0e2589fe3b/distrobox-export#L456
When exporting the matching is pretty loose (surrounded by grabby
.*
regex) and when exporting something with a short name (1-3 characters) it can match a lot of things. Or in the case nothing is supplied it matches everything! (There should probably be a check whetherexported_app
is empty.)I don't know what a good approach to the matching problem would be, since it's nice for users to be able to export something by a name guess that's only close enough. Maybe a confirmation dialog if it matches multiple desktop files?
I think it might be a good idea to have a flag to enable/disable searching of the
Name=
field. Then when exporting by the command name you could useExec=${exported_app}
(notice the space at the end) to only match the provided command name. Since I'd assume someone using the command name would provide the full one. PS the.*
is not needed at the end.