Look for user editable config files in gnc_userconfig_dir instead of gnc_userdata_dir

At present these are
- log.conf
- config-user.scm (previously config.user-2.0)

Implement one-time migration of these files to the proper directory if they previously exist
Look for a log.conf file in gnc_userconfig_dir instead of gnc_userdata_dir

Note this commit also uses boost::locale::translate for the first time.
We may need to fine-tune our use, but in the current state strings marked
for translation using that function are already picked up for gnucash.pot.
This commit is contained in:
Geert Janssens
2018-02-20 00:48:28 +01:00
parent beff795130
commit 61a21d12c6
6 changed files with 183 additions and 29 deletions

View File

@@ -91,9 +91,9 @@ gchar *gnc_path_find_localized_html_file (const gchar *file_name);
* function will also try to copy files from $HOME/.gnucash
* to there if that old location exists.
*
* @return whether files got copied from the old location.
* @return a migration message when files got copied from the old location, NULL otherwise
*/
gboolean gnc_filepath_init (void);
char * gnc_filepath_init (void);
const gchar *gnc_userdata_dir (void);
gchar *gnc_build_userdata_path (const gchar *filename);