Sunday, May 5, 2024
 Popular · Latest · Hot · Upcoming
8
rated 0 times [  8] [ 0]  / answers: 1 / hits: 8473  / 2 Years ago, wed, december 8, 2021, 3:24:02

I have got a wine installtion with a couple of games, most of which work fabulously. However, wine creates directories in my home for the player data, saves, etc.



Is there a way to have those in ~/.winesaves or something similar? I would prefer wine not littering my home directory.



(wine: 1.5.27, game in question was SCII and DE:IW)






edit to clarify:



Everything in ~/.wine is fine and good, but I don't want applications to create ~/GameSaves or the likes.


More From » wine

 Answers
4

You may need to experiment with the sandbox option present in winetricks, which may help you as all the Wine symlinks to $HOME are removed when that setting is applied to the default WINEPREFIX with winetricks sandbox.



However, wine still has your user's permissions in the home folder, and often when installing a new program, an action in the installation can trigger the sandbox to be removed. So it is not really a true 'sandbox' at all, but it may be helpful for your use case.



At the official wine FAQ it is noted that:




Winetricks does have a sandbox verb that does at least a partial job of isolating Wine programs from the rest of your system. It protects against errors rather than malice. It's useful for, e.g., keeping games from saving their settings in random subdirectories of your home directory.




On the official winetricks page, it is explained that




If you want to isolate an app so that it doesn't save anything to your home directory, you can try 'winetricks sandbox'. That will remove the symlinks to your home directory. Do this before saving any data, or you'll have to copy old saved data from your home directory into $WINEPREFIX/drive_c/users/$USERNAME.




Important notes




  • The wine sandbox option will likely need to be used repeatedly, i.e. include it in a launcher script that runs winetricks sandbox and then launches your game, as a number of things in wine can trigger the rebuilding of the symlinks.


  • The folder of saves you have already generated will need to be moved to your WINEPREFIX, e.g /home/$USER/.wine/drive_c/users/$USER/"My Documents" in order for you to resume your game. If wine has just created a folder called ~/gamesaves, simply move that folder to the location mentioned above. Otherwise, observe the directory structure; if a game save folder is ~/Documents/Syberia/save make sure you create an equivalent in /home/$USER/.wine/drive_c/users/$USER/"My Documents".


  • When you install a game in the future, make sure you run winetricks sandbox at the start, so that the game will automatically start using your WINEPREFIX as the save location, and not a folder in your $HOME.



[#31855] Wednesday, December 8, 2021, 2 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
aclavadoug

Total Points: 317
Total Questions: 103
Total Answers: 125

Location: Bangladesh
Member since Wed, Mar 24, 2021
3 Years ago
;