Add Support for XDG Base Directory
Please Describe The Problem To Be Solved
nxc currently unnecessarily populates the user's home directory by storing all of its files inside ~/.nxc.
Solution
This can be fixed by adding support for the XDG Base Directory. By supporting this, the nxc.conf can be stored in XDG_CONFIG_HOME/nxc and the other files in their correct directories.
@Marshall-Hallenbeck @NeffIsBack if you guys want this, I can work on it. Use the XDG env variables if defined, otherwise default to the current
Would be neat to have imo, but first there has to be some refactoring, so that ever flag/module respects the NXC_VARS in /nxc/paths.py
@NeffIsBack I could start by unifying that first - should I open a different issue for refactoring modules to use NXC_VARS? Then i'm happy to tackle this as well
All good, no issue necessary. You can open up a Draft PR if you want as soon as you made progress, so it is public. But that's not required :)
@NeffIsBack ok I will, and cheers for the quick replies! :)
Instead of moving the .nxc folder to the XDG_CONFIG_HOME, we decided to just give the user the option to specify a different location by setting an env variable NXC_PATH which would then serve as the nxc home dir. Hopefully that is roughly what you were looking for @sdushantha
@NeffIsBack Thats perfect, thank you!