Open a file directly with a WINE application

Moderator: Forum moderators

Post Reply
User avatar
amethyst
Posts: 2355
Joined: Tue Dec 22, 2020 6:35 am
Has thanked: 55 times
Been thanked: 473 times

Open a file directly with a WINE application

Post by amethyst »

Code: Select all

SET=`winepath -w "$*"`
wine FullPathOfApplicationExecutable "$SET"

In many (most ) cases a Windows program run with WINE will not open a specific file directly, you need to open the program first and then from its "open" menu open the file. The above code/script deals with this issue.
So when I want to open a file directly with my chosen WINE application, I right-click it and run the script from the Open With menu. Voila.
You can also set the default run action (file association). Right-click the file you want to open with the script > select Set Run Action > Select 'Only for the type...' > drag and drop the script into the window.

Post Reply

Return to “WINE”