Previous Thread
Next Thread
Print Thread
#109274 - 03/29/17 11:12 AM Fist look for .qmc folder in working directory  
Joined: Jun 2015
Posts: 55
NLS Offline
Member
NLS  Offline
Member

Joined: Jun 2015
Posts: 55
Well title says it all.
I read that other thread about QMC2 portability and realized, that if QMC2 init was a bit smarter, it wouldn't (in most cases) need a parameter to define own .ini location.

Instead of using user home as first location for .qmc directory, it should first look in OWN working directory if the path exists.
OR if you want to keep user home as first location (which also makes sense), at least change the behavior so that if there is no .qmc in user directory, to then look for .qmc in working directory and use that AND ONLY IF there is no .qmc in working directory to then create .qmc in user directory.

This is a way more normalized process, that will allow for much more easier portable setups (with the help of relative paths in the config - as already allowed, which IIRC was also my request years ago and you implemented). smile

#109276 - 03/29/17 01:58 PM Re: Fist look for .qmc folder in working directory [Re: NLS]  
Joined: May 2008
Posts: 4,857
qmc2 Online content
qmc2  Online Content

Very Senior Member

Joined: May 2008
Posts: 4,857
Germany
Your proposal isn't even the usual (or right) way on Windows wink... whatever "smart" way you want can be realized with the "-config_path" parameter. The default behavior is following a platform-independent and commonly used concept.


A mind is like a parachute. It doesn't work unless it's open. [Frank Zappa]

We're searching for QMC2 translators and support for existing translations. Interested? See here!
#109277 - 03/29/17 02:29 PM Re: Fist look for .qmc folder in working directory [Re: NLS]  
Joined: Mar 2001
Posts: 15,772
R. Belmont Offline
R. Belmont  Offline

Very Senior Member

Joined: Mar 2001
Posts: 15,772
USA
His proposal is similar to what MAME does, actually. On Windows, it looks in the EXE directory (I should fix that to know about C:\Users\foo\Documents\My Games\MAMEdev\MAME sometime) and then in a folder named "ini" in the EXE directory. On Linux it looks in $HOME/.mame/ and then the EXE directory and then the ini folder. On Mac it looks in $HOME/Library/Application Support/MAME/, then $HOME/.mame/, then the EXE directory, then the ini folder.

#109279 - 03/29/17 06:47 PM Re: Fist look for .qmc folder in working directory [Re: NLS]  
Joined: May 2008
Posts: 4,857
qmc2 Online content
qmc2  Online Content

Very Senior Member

Joined: May 2008
Posts: 4,857
Germany
One could start MAME or QMC2 from anywhere (CWD-wise), but I wouldn't want it to search for the config in the CWD - except when the user starts it with "-config_path ." for example. Anyway, my point is that the "-config_path" option is the only thing you need to specify if you want it differently than what the default does. I actually don't see why this appears to be a problem to some users.

Last edited by qmc2; 03/29/17 06:47 PM.

A mind is like a parachute. It doesn't work unless it's open. [Frank Zappa]

We're searching for QMC2 translators and support for existing translations. Interested? See here!
#109282 - 03/30/17 06:00 PM Re: Fist look for .qmc folder in working directory [Re: qmc2]  
Joined: Jun 2015
Posts: 55
NLS Offline
Member
NLS  Offline
Member

Joined: Jun 2015
Posts: 55
Originally Posted by qmc2
One could start MAME or QMC2 from anywhere (CWD-wise), but I wouldn't want it to search for the config in the CWD - except when the user starts it with "-config_path ." for example. Anyway, my point is that the "-config_path" option is the only thing you need to specify if you want it differently than what the default does. I actually don't see why this appears to be a problem to some users.


Transparent portability is the answer.
I explained rather thoroughly in initial post (as I am usually doing even when not asked to).
Anyway, your prerogative.

Last edited by NLS; 03/30/17 06:00 PM.
#109283 - 03/30/17 06:29 PM Re: Fist look for .qmc folder in working directory [Re: NLS]  
Joined: Mar 2001
Posts: 15,772
R. Belmont Offline
R. Belmont  Offline

Very Senior Member

Joined: Mar 2001
Posts: 15,772
USA
You can just include a batch file that runs QMC2 with "-config_path ." to get the results you're looking for. I'd prefer if he matched MAME semantics, but it's not the end of the world if he doesn't.


Moderated by  qmc2 

Who's Online Now
2 registered members (Carbon, Dam0), 9 guests, and 3 spiders.
Key: Admin, Global Mod, Mod
Shout Box
Forum Statistics
Forums9
Topics8,453
Posts109,705
Members4,766
Most Online225
May 26th, 2014
Powered by UBB.threads™ PHP Forum Software 7.6.0
Page Time: 0.024s Queries: 14 (0.007s) Memory: 4.9690 MB (Peak: 5.1653 MB) Zlib enabled. Server Time: 2017-12-12 10:15:20 UTC