etxmato / emma_02

Emma 02 - RCA CDP 1802 Multi-system Emulator
Other
39 stars 9 forks source link

emma02.ini file should not be in ~/emma_02/data #5

Closed etxmato closed 7 years ago

etxmato commented 7 years ago

Instead it should be in ~/emma_02 on Linux

On windows maybe it should stay as is - to be looked into On OS X either the same as on Linux or maybe emma_02.ini should be in the application/emma_02 folder

phiber1 commented 7 years ago

I was thinking it should be "~/.emma_02". Notice the dot. This is much more in line with unix/linux convention.

etxmato commented 7 years ago

Yes I had seen the dot, however I got very strong comments from other Linux users that the installation should be done in one folder. So that is why I suggested ~/emma_02, I can go for a .emma_02 for the main .ini file but then I need to keep the config files in ~/emma_02 which also doesn't sound very 'clean'

phiber1 commented 7 years ago

Why can't the one and only directory be the one with the dot? All .ini files go under .emma_02... Sounds pretty simple to me.

On Aug 4, 2017 11:32 PM, "etxmato" notifications@github.com wrote:

Yes I had seen the dot, however I got very strong comments from other Linux users that the installation should be done in one folder. So that is why I suggested ~/emma_02, I can go for a .emma_02 for the main .ini file but then I need to keep the config files in ~/emma_02 which also doesn't sound very 'clean'

— You are receiving this because you commented.

Reply to this email directly, view it on GitHub https://github.com/etxmato/emma_02/issues/5#issuecomment-320416639, or mute the thread https://github.com/notifications/unsubscribe-auth/AMEKmG42vrls0LZG0VqyTIaJ-FGVP4mSks5sVAxxgaJpZM4OtoWS .

etxmato commented 7 years ago

It could, but then I need to 'install' files to both .emma_02 (config files) and emma_02 (data files); which according to previous comments, I think from Chuck, is a real 'no no' on Linux?

phiber1 commented 7 years ago

I don't know who the people are whom you're referencing. The normal, conventional way of doing things in Linux or any Unix would be to put per-user configs in ~/.emma_02 and the global system images under /usr/share/... which an individual user is free to copy wherever they want. The initial configs conceivably should also have default copies in /usr/share in case a user ever needs to revert back.

On Aug 5, 2017 2:33 AM, "etxmato" notifications@github.com wrote:

It could, but then I need to 'install' files to both .emma_02 (config files) and emma_02 (data files); which according to previous comments, I think from Chuck, is a real 'no no' on Linux?

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/etxmato/emma_02/issues/5#issuecomment-320433438, or mute the thread https://github.com/notifications/unsubscribe-auth/AMEKmJr5LVCuri6uLH2ymSNcPNOxgyR2ks5sVDbqgaJpZM4OtoWS .

etxmato commented 7 years ago

Ok, so you think it is ok if I do like: /usr/share/emma_02 for executable, images, copy of menu config files etc. ~/.emma_02 for config files including menu config files ~/emma_02 for ROM and SW files

In the current set-up I don't use /usr/share due to previous 'complaints' from at least 2 users. They both wanted one folder only either /usr/share or ~/

phiber1 commented 7 years ago

People will confuse ~/.emma_02 with and without the dot. There should just be one. If that means putting data with the images in it, so be it, people are welcome to move it. As far as the executable, that should be in /usr/bin if installed from a package, and /usr/local/bin if built from source.

On Aug 5, 2017 3:12 PM, "etxmato" notifications@github.com wrote:

Ok, so you think it is ok if I do like: /usr/share/emma_02 for executable, images, copy of menu config files etc. ~/.emma_02 for config files including menu config files ~/emma_02 for ROM and SW files

In the current set-up I don't use /usr/share due to previous 'complaints' from at least 2 users. They both wanted one folder only either /usr/share or ~/

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/etxmato/emma_02/issues/5#issuecomment-320473197, or mute the thread https://github.com/notifications/unsubscribe-auth/AMEKmHmjVpiywLD3WcRUXFoLFC1AnSNnks5sVOjrgaJpZM4OtoWS .

etxmato commented 7 years ago

Ok, think I'm getting there so assuming we go from a package:

Now when should I copy the menu config files to ~/.emma_02? Or should I put them in ~/.emma_02 during installation?

And where to put the SW and ROMs? is it better to NOT include them in the package? maybe better like a seperate zip? Still where should I expect the user to put these folder? or should I not assume any default location?

phiber1 commented 7 years ago

Well, technically, when installing from an actual package like a .deb, binaries typically go in /usr/bin and associated files under /usr/share. It's when a user builds from source that things typically go in /usr/local. Likewise if they're installing from a zip file, but then they're likely manually copying files to their system-wide destinations, so /usr/local is typically chosen.

I would definitely install the config files under ~/.emma_02 with the understanding that the user is informed that the default ones are under /usr/share/..., should he/she ever need to restore/edit a config for some reason.

Not sure about the data images... You could include a separate zip file, but then the emulators are pretty useless without any images, so it's not like they're optional... I'm tempted to just include them in the one main zip. I'd say either in ~/.emma_02/data, or in something like ~/emma_data. In either case, the user can always move them and change the location of the data directory.

-M

On Sun, Aug 6, 2017 at 1:48 PM, etxmato notifications@github.com wrote:

Ok, think I'm getting there so assuming we go from a package:

  • bin in usr/local/bin
  • images, copy of menu config files in usr/local/share
  • and on first start-up I create emma02.ini in ~/.emma_02

Now when should I copy the menu config files to ~/.emma_02? Or should I put them in ~/.emma_02 during installation?

And where to put the SW and ROMs? is it better to NOT include them in the package? maybe better like a seperate zip? Still where should I expect the user to put these folder? or should I not assume any default location?

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/etxmato/emma_02/issues/5#issuecomment-320531721, or mute the thread https://github.com/notifications/unsubscribe-auth/AMEKmJT1OuHooR6AmyrlLN-TkozjFsdnks5sViaZgaJpZM4OtoWS .

etxmato commented 7 years ago

got it, thanks!

etxmato commented 7 years ago

Just committed some code for the first step to solve this one, it does need more testing but idea is that it uses the following locations for the emma_02.ini and menu configuration files: Linux: ~/.emma_02 OS X: ~/Library/Preferences/Emma 02 Windows: C:\Users\username\AppData\Roaming.emma_02

On Linux there will already be a .emma_02 file which needs to be deleted first, otherwise you will get a crash. Maybe I should add a few lines to delete this automatically!

After startup folders will be created but as I don't have an installer as yet there are no menu config files created. For now you need to copy them in manually from the old data directory.

I'm not sure if the windows solution is 'ok', formally I think I should store this in C:\Users\username\AppData\Roaming\Emma 02 but to do so I will need to move the data files somewhere else. Might still do that...

etxmato commented 7 years ago

Checked in updates as follows: I decided to go for emma02_ini and menu config files: Linux: ~/.emma_02 OS X: ~/Library/Preferences/Emma 02 Windows: C:\Users\username\AppData\Roaming\Emma 02 Config

Default location for 1802 SW files: Linux ~/emma_02_data OS X ~/Emma 02 Windows: C:\Users\username\AppData\Roaming\Emma 02

I know they are all different but trying to keep it logic for users for applicable platforms. I would have preferred to move the 1802 SW files to C:\Users\username\Emma 02, which is more inline with OS X and I think better. However I'm struggling to find a way to 'install' files in that folder with the Inno setup/script tools I use on Windows.

I also did some corrections for portal mode.

Need to do more testing and also correct help files to show correct locations.

etxmato commented 7 years ago

I think this one can also finally be closed. I made one bug fix last night which caused problems on an initial clean install.