This patch changes the default value of 'dict-dir' to correspond to ~/.guix-profile/lib/aspell rather than $prefix/lib/aspell-X.Y. This is not strictly necessary for the 'aspell' program itself since one can simply set "ASPELL_CONF=dict-dir $HOME/.guix-profile/lib/aspell". However it is necessary for applications that use libaspell since 'ASPELL_CONF' is not honored in this case. See . --- a/common/config.cpp +++ b/common/config.cpp @@ -651,7 +651,20 @@ namespace acommon { } else { // sep == '|' assert(replace[0] == '$'); const char * env = getenv(replace.c_str()+1); - final_str += env ? env : second; + if (env) { + final_str += env; + } else if (second[0] == '$') { + // Expand the right-hand side of '|', which starts with a + // reference to an environment variable. + auto slash = second.find('/'); + String variable = second.substr(1, slash - 1); + const char * env = getenv(variable.c_str()); + String value = env ? String(env) : ""; + value += second.substr(slash, second.size() - slash); + final_str += value; + } else { + final_str += second; + } } replace = ""; in_replace = false; @@ -1349,6 +1349,9 @@ namespace acommon { # define REPL ".aspell..prepl" #endif +#undef DICT_DIR +#define DICT_DIR "<$ASPELL_DICT_DIR|$HOME/.guix-profile/lib/aspell>" + static const KeyInfo config_keys[] = { // the description should be under 50 chars {"actual-dict-dir", KeyInfoString, "", 0} 4dc98ed439f32d2a903ff866ae345234c0f'/>
AgeCommit message (Expand)Author
2020-02-09Update e-mail address for Jakob L. Kreuze....Tobias Geerinckx-Rice
2019-12-08machine: Remove unnecessary record self-referencing bindings....Ludovic Courtès
2019-12-07machine: ssh: Deprecate missing 'host-key' field....Ludovic Courtès
2019-12-04machine: ssh: <machine-ssh-configuration> can include the host key....Ludovic Courtès
2019-10-22machine: digital-ocean: Rename 'enable-ipv6' to 'enable-ipv6?'....Ludovic Courtès
2019-10-22machine: Implement 'digital-ocean-environment-type'....Jakob L. Kreuze
2019-08-17machine: ssh: Fix sanity checks....宋文武
2019-08-16machine: Use 'become-command'....Jakob L. Kreuze
2019-08-15machine: Automatically authorize the coordinator's signing key....Jakob L. Kreuze
2019-08-15machine: Implement 'roll-back-machine'....Jakob L. Kreuze
2019-08-15machine: Allow non-root users to deploy....Jakob L. Kreuze
2019-08-14remote: Build derivations appropriate for the remote's...Jakob L. Kreuze
2019-08-07machine: Add 'build-locally?' field for managed hosts....Jakob L. Kreuze
2019-08-06machine: Implement safety checks....Jakob L. Kreuze
2019-08-06machine: Rename 'system' field....Jakob L. Kreuze
2019-07-26guix system: Add 'reconfigure' module....Jakob L. Kreuze
2019-07-18machine: Fix typo....Tobias Geerinckx-Rice
2019-07-06gnu: Add machine type for deployment specifications....Jakob L. Kreuze