FreeCol / freecol

FreeCol: FreeCol is a turn-based strategy game based on the old game Colonization, and similar to Civilization. The objective of the game is to create an independent nation.
GNU General Public License v2.0
585 stars 170 forks source link

Create config directory for freecol prefs if not present on Mac OS X #64

Closed DonWaugaman closed 4 years ago

DonWaugaman commented 4 years ago

This is a pretty basic patch which changes the getMacOSXDirs routine to use RequireDirectory to create the config directory for storing FreeCol preferences if it does not yet exist.

I've tested this on Mac OS 10.15 and 10.11. Testing was done by deleting the preferences directory and verifying that it did not start correctly with the old version of the routine, then by installing the new version of the app and making sure it did start correctly.

With this patch, the Mac app version as generated by 'ant tarMacJavaBundle' should work correctly on an out-of-the-box Mac with Oracle Java 1.8+ installed.

wintertime commented 4 years ago

Thank you. I merged this manually, although I could only do very basic testing. I also triggered a new Nightly Release, so people can test it (please do).