Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Makehuman working dir should be hidden #5

Closed
es20490446e opened this issue Nov 7, 2017 · 14 comments

Comments

@es20490446e
Copy link

es20490446e commented Nov 7, 2017

In Linux the Makehuman working dir is "$HOME/makehuman". It would be nice if it was "$HOME/.config/makehuman" instead, so the user folder stays clean from config files.

@Aranuvir

This comment has been minimized.

Copy link
Collaborator

Aranuvir commented Nov 8, 2017

I'm not going to reject the proposal, because it merits a discussion.

In my opinion it is not beneficial moving the makehuman folder to .config. The working directory stores more than configuration files. All custom assets, skeletons and targets as well as plugins are stored in the folder, too. There are very limited tools inside of MakeHuman to organize and remove these files. In file managers .config is usually hidden. And it is quite annoying clicking through multiple (hidden) subfolders.

As a hint for the OP: there is an undocumented command line option --home-location to change the location of the working directory on the master branch. This behaviour is altered on my branches by reading the environment variable "MH_HOME_LOCATION".

@Aranuvir Aranuvir self-assigned this Nov 8, 2017
@es20490446e

This comment has been minimized.

Copy link
Author

es20490446e commented Nov 8, 2017

See it this way: if every application followed that design the home folder would be full of directories.

Even having the home folder full of hidden directories looks convoluted.

@Aranuvir

This comment has been minimized.

Copy link
Collaborator

Aranuvir commented Nov 9, 2017

As I stated above, the makehuman folder mainly does not contain configuration files, but working files. So it does not really fit in the .config folder. Is there any other folder it would fit better? Taking a look at FHS 3.0 there is no definition for any folder in /home. We cannot even expect to find a .config folder. Technically it is trivial to check the existence of a .config folder during start up process and use it, when it exists. Though I'd recommend leaving things as they currently are.
For those who need a different behaviour there are solutions, as I have already mentioned.

@es20490446e

This comment has been minimized.

Copy link
Author

es20490446e commented Nov 13, 2017

The important part in my view it's not having it visible right away in the user folder.

Preferably by making it hidden, or less conveniently by putting it into the Documents folder. Or by letting the user decide the folder.

@rwbaer

This comment has been minimized.

Copy link
Collaborator

rwbaer commented Nov 19, 2017

Admittedly, I am often confused by unix-alike directory conventions, so my comments need to be taken in that context.

Aranuvir already points out that there are very few configuration assets within makehuman folder. If I had to enumerate them, I would say those ending with .ini: so settings.ini, shortcuts.ini, and maybe mouse.ini and help.ini. These are located 1 level down in the v1 or v1py3 subdirectory.

Relative to es20490446e's last comment, I'll point out that on both Windows and Mac we do indeed put the makehuman folder in the Documents directory and not straight away in the home folder. If it is not already there on other unix-alike OSes, this would be an internally consistent change and seems useful in many ways.

Given the normal (heavy) use of the makehuman folder by high-end MakeHuman users, it does not make much sense, and would be annoying, to hide it by default. One could move and hide the .ini files in a configuration area, but this would not seem to address "clutter" in the home directory and they have never gotten in the way where they are. If we move them, we have cross-platform decisions that are not clear.

@es20490446e

This comment has been minimized.

Copy link
Author

es20490446e commented Nov 19, 2017

That makes sense to me.

@Aranuvir

This comment has been minimized.

Copy link
Collaborator

Aranuvir commented Nov 19, 2017

Quote Rob:

I'll point out that on both Windows and Mac we do indeed put the makehuman folder in the Documents directory and not straight away in the home folder. If it is not already there on other unix-alike OSes, this would be an internally consistent change and seems useful in many ways.

Best practice would be, let the user decide where to locate the makehuman folder. Unfortunately this can only be done in command line mode on first run, because the makehuman folder is created in a very early stage on start up. Assuming that most users will not start MakeHuman from a shell, this solution is obsolete.

The other solution is to move the makehuman folder to a 'Documents' folder. As I stated above, we cannot always expect to find this folder. Though normally an equivalent to a Documents folder is created by the desktop, with its name depending on the localization. This is handled by xdg-user-dirs-update and stored in .config/user-idrs.dirs. It is not to difficult to write a parser for this file and in case it returns an equivalent Documents folder, the Application will create the makehuman folder there, otherwise in $HOME.

I've created a new branch called 'xdg_folder' which introduces the new behavior.

Fix exists, needs testing especially on platforms other than Linux, too.

@es20490446e

This comment has been minimized.

Copy link
Author

es20490446e commented Nov 19, 2017

Thank you. When I have a moment I will test this: added to my todo list.

@Aranuvir

This comment has been minimized.

Copy link
Collaborator

Aranuvir commented Nov 19, 2017

... which leads to the question if we should automatically copy data from the old location if it exists? First start could take a while then, my user data folder is round about 1GB (so a basic test was acceptable on my ssd, but not every users has a ssd in her/his system ...)

@Aranuvir

This comment has been minimized.

Copy link
Collaborator

Aranuvir commented Nov 19, 2017

... and of course we need to adapt the other MakeThings stuff ...

@es20490446e

This comment has been minimized.

Copy link
Author

es20490446e commented Nov 19, 2017

The least surprising thing would be leaving the folder were it was when created, at least if the user can choose where the folder is located.

@Aranuvir

This comment has been minimized.

Copy link
Collaborator

Aranuvir commented Nov 20, 2017

I don't think it is possible to move the makehuman folder at run time.

@es20490446e

This comment has been minimized.

Copy link
Author

es20490446e commented Nov 22, 2017

The branch works for me in Arch Linux. It creates the MakeHuman folder in ~/Documents.

@Aranuvir

This comment has been minimized.

Copy link
Collaborator

Aranuvir commented Jan 13, 2019

Fixed...

@Aranuvir Aranuvir closed this Jan 13, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.