Open mikefaille opened 7 years ago
Interesting... it works with nixpkgs-unstable
but not release-16.09
. The /tmp/jna8713236742918782736.libhunspell-linux-x86-64.so
exists in both cases.
I observed a probably related issue: i have installed several hunspell
dictionaries, but only en_US
(hunspell-dict-en-us-wordlist-2014.11.17
) got recognised by applications such as Evolution email client, not even other English dictionaries (en_GB-ise
, en_GB-ize
).
Is this the same issue? What could make en_US
special?
@alexeymuranov how did you install hunspell and the dictionaries? what does $ hunspell -D
say?
@pbogdan, to get English (United States) appear in spell checking preferences in Evolution, it is enough to do
nix-env -i hunspell-dict-en-us-wordlist-2014.11.17
Not even installing hunspell
is necessary.
Here is what i actually have:
§ nix-env -q | grep hunspell
hunspell-1.3.3
hunspell-dict-en-gb-ise-wordlist-2014.11.17
hunspell-dict-en-gb-ize-wordlist-2014.11.17
hunspell-dict-en-us-wordlist-2014.11.17
hunspell-dict-fr-any-dicollecte-5.3
hunspell-dict-fr-moderne-dicollecte-5.3
§ hunspell -D
SEARCH PATH:
.::/usr/share/hunspell:/usr/share/myspell:/usr/share/myspell/dicts:/Library/Spelling:/home/alexey/.openoffice.org/3/user/wordbook:.openoffice.org2/user/wordbook:.openoffice.org2.0/user/wordbook:Library/Spelling:/opt/openoffice.org/basis3.0/share/dict/ooo:/usr/lib/openoffice.org/basis3.0/share/dict/ooo:/opt/openoffice.org2.4/share/dict/ooo:/usr/lib/openoffice.org2.4/share/dict/ooo:/opt/openoffice.org2.3/share/dict/ooo:/usr/lib/openoffice.org2.3/share/dict/ooo:/opt/openoffice.org2.2/share/dict/ooo:/usr/lib/openoffice.org2.2/share/dict/ooo:/opt/openoffice.org2.1/share/dict/ooo:/usr/lib/openoffice.org2.1/share/dict/ooo:/opt/openoffice.org2.0/share/dict/ooo:/usr/lib/openoffice.org2.0/share/dict/ooo
AVAILABLE DICTIONARIES (path is not mandatory for -d option):
Can't open affix or dictionary files for dictionary named "en_US".
22:54:00[alexey@Alexey-BU403UA-NixOS:~]
@alexeymuranov this looks similar to an issue I had when setting up hunspell to be used as spellchecker in emacs. Initially I installed hunspell and dictionaries by referencing package names directly like you did but that would give me an installation where the dictionaries were not included in hunspell's search path. What worked for me was instead using hunspellWithDicts From shell you should be able to use it as follows:
$ nix-instantiate -E 'with import <nixpkgs> { }; hunspellWithDicts [ hunspellDicts.en-gb-ise ]'
warning: you did not specify ‘--add-root’; the result might be removed by the garbage collector
/nix/store/9ha2k5wpz8a5akl4py1836mbyk85fj7b-hunspell-with-dicts-1.3.3.drv
$ nix-env -i /nix/store/9ha2k5wpz8a5akl4py1836mbyk85fj7b-hunspell-with-dicts-1.3.3.drv
That should give you hunspell which has all the extra dictionaries included in the search path by default.
Not sure but you may also need to first uninstall the currently installed hunspell and dictionaries. For installing via ~/.config/nixpkgs.nix
you can add:
myhunspell = hunspellWithDicts [ hunspellDicts.en-gb-ise ];
within packageOverrides
section and then reference myhunspell
within your package set.
Also not sure about Evolution but I found it easiest to set a default dictionary with an environment variable like so:
export DICTIONARY=en_GB-ise
HTH.
@pbogdan, i tried with ~/.config/nixpkgs.nix
:
{ #...
myHunspell = hunspellWithDicts [
hunspellDicts.en-gb-ise
hunspellDicts.en-gb-ize
hunspellDicts.en-us
hunspellDicts.fr-any
hunspellDicts.fr-moderne
];
}
nix-env -iA nixos.myHunspell
(after uninstalling everything for Hunspell), but still in Evolution i only see Hebrew (?).
unstable.hunspellWithDicts [ unstable.hunspellDicts.en-us ];
still breaks on "isn't":
Hunspell 1.7.0
isn't
& isn 9 0: sin, ins, ism, is, in, inn, ion, isl, is n
*
Thank you for your contributions.
This has been automatically marked as stale because it has had no activity for 180 days.
If this is still important to you, we ask that you leave a comment below. Your comment can be as simple as "still important to me". This lets people see that at least one person still cares about this. Someone will have to do this at most twice a year if there is no other activity.
Here are suggestions that might help resolve this more quickly:
This in home manager worked for me:
languagetool
(myHunspell = hunspellWithDicts [
hunspellDicts.en-gb-ise
hunspellDicts.en-gb-ize
hunspellDicts.en-us
hunspellDicts.fr-any
hunspellDicts.fr-moderne
])
Hello @mikefaille :wave:
I tried to reproduce this issue, but it seems like everything seems to be working. Is this still an issue you experience? If not, would you be able to close this issue?
(I'm going through issues marked as stale to see what can be resolved. If this is still an issue that you have then don't mind me).
Issue description
Work with English corrector but not using spanish or french one.
Steps to reproduce
Technical details
16.09.git.3414ae5 (Flounder)
nix-env (Nix) 1.11.4