FS#59157 - [hunspell-es] Split Spanish dictionaries by country like English

Attached to Project: Arch Linux
Opened by Juan Simón (j1simon) - Wednesday, 27 June 2018, 12:44 GMT
Last edited by Antonio Rojas (arojas) - Tuesday, 17 July 2018, 18:56 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To Antonio Rojas (arojas)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

The English dictionaries are split in several packages by country:
extra/hunspell-en 2017.01.22-2
English (US, UK, etc.) hunspell dictionaries
extra/hunspell-en_AU 2017.01.22-2
AU English hunspell dictionaries
extra/hunspell-en_CA 2017.01.22-2
CA English hunspell dictionaries
extra/hunspell-en_GB 2017.01.22-2
GB English hunspell dictionaries
extra/hunspell-en_US 2017.01.22-2
US English hunspell dictionaries

But Spanish dictionaries are all in same package but they are not the same:
hunspell-es /usr/share/hunspell/es_ANY.dic
hunspell-es /usr/share/hunspell/es_AR.dic
hunspell-es /usr/share/hunspell/es_BO.dic
hunspell-es /usr/share/hunspell/es_CL.dic
hunspell-es /usr/share/hunspell/es_CO.dic
hunspell-es /usr/share/hunspell/es_CR.dic
hunspell-es /usr/share/hunspell/es_CU.dic
hunspell-es /usr/share/hunspell/es_DO.dic
hunspell-es /usr/share/hunspell/es_EC.dic
hunspell-es /usr/share/hunspell/es_ES.dic
hunspell-es /usr/share/hunspell/es_GT.dic
hunspell-es /usr/share/hunspell/es_HN.dic
hunspell-es /usr/share/hunspell/es_MX.dic
hunspell-es /usr/share/hunspell/es_NI.dic
hunspell-es /usr/share/hunspell/es_PA.dic
hunspell-es /usr/share/hunspell/es_PE.dic
hunspell-es /usr/share/hunspell/es_PR.dic
hunspell-es /usr/share/hunspell/es_PY.dic
hunspell-es /usr/share/hunspell/es_SV.dic
hunspell-es /usr/share/hunspell/es_UY.dic
hunspell-es /usr/share/hunspell/es_VE.dic

It's very annoying. For example, in the case of Firefox which uses the system dictionaries, it shows 20 variants of dictionaries for Spanish! (I attach a screenshot).
Thanks.
This task depends upon

Closed by  Antonio Rojas (arojas)
Tuesday, 17 July 2018, 18:56 GMT
Reason for closing:  Implemented
Additional comments about closing:  hunspell-es 2.3-2
Comment by A. Bosch (progandy) - Wednesday, 27 June 2018, 20:50 GMT
In the case of firefox, it is possible to symlink the desired dictionaries in a new directory and set that with spellchecker.dictionary_path in about:config. That leaves all dictionaries available for use in other applications.

https://askubuntu.com/a/641017
Comment by Antonio Rojas (arojas) - Friday, 29 June 2018, 09:36 GMT
Feel free to provide a PKGBUILD, I don't plan to spend time on this.
Comment by Juan Simón (j1simon) - Friday, 29 June 2018, 10:27 GMT
I don't understand this resistance to do something right.
Which is the reason to split English dictionaries by country and to do not the same with Spanish?
Anyway, I'm doing the modified PKGBUILD.
Comment by Juan Simón (j1simon) - Friday, 29 June 2018, 12:00 GMT
This is the modified PKGBUILD: https://pastebin.com/qKR6Cb0f

I've tested it and it works.
Comment by Antonio Rojas (arojas) - Friday, 29 June 2018, 17:50 GMT
Thanks. For the upgrade to work, new packages need to conflict with hunspell-es, and at least one (probably -ANY) needs to replace it.
Comment by Juan Simón (j1simon) - Saturday, 30 June 2018, 09:40 GMT
I haven't split `hyphen-es` nor `mythes-es` because they are symlinks to the same file:
```
hyph_es_ANY.dic
hyph_es_AR.dic -> hyph_es_ANY.dic
hyph_es_BO.dic -> hyph_es_ANY.dic
hyph_es_CL.dic -> hyph_es_ANY.dic
hyph_es_CO.dic -> hyph_es_ANY.dic
hyph_es_CR.dic -> hyph_es_ANY.dic
hyph_es_CU.dic -> hyph_es_ANY.dic
hyph_es_DO.dic -> hyph_es_ANY.dic
hyph_es_EC.dic -> hyph_es_ANY.dic
hyph_es_ES.dic -> hyph_es_ANY.dic
hyph_es_GT.dic -> hyph_es_ANY.dic
hyph_es_HN.dic -> hyph_es_ANY.dic
hyph_es_MX.dic -> hyph_es_ANY.dic
hyph_es_NI.dic -> hyph_es_ANY.dic
hyph_es_PA.dic -> hyph_es_ANY.dic
hyph_es_PE.dic -> hyph_es_ANY.dic
hyph_es_PR.dic -> hyph_es_ANY.dic
hyph_es_SV.dic -> hyph_es_ANY.dic
hyph_es_UY.dic -> hyph_es_ANY.dic
hyph_es_VE.dic -> hyph_es_ANY.dic
```
```
th_es_AR_v2.dat -> th_es_ES_v2.dat
th_es_AR_v2.idx -> th_es_ES_v2.idx
th_es_BO_v2.dat -> th_es_ES_v2.dat
th_es_BO_v2.idx -> th_es_ES_v2.idx
th_es_CL_v2.dat -> th_es_ES_v2.dat
th_es_CL_v2.idx -> th_es_ES_v2.idx
th_es_CO_v2.dat -> th_es_ES_v2.dat
th_es_CO_v2.idx -> th_es_ES_v2.idx
th_es_CR_v2.dat -> th_es_ES_v2.dat
th_es_CR_v2.idx -> th_es_ES_v2.idx
th_es_CU_v2.dat -> th_es_ES_v2.dat
th_es_CU_v2.idx -> th_es_ES_v2.idx
th_es_DO_v2.dat -> th_es_ES_v2.dat
th_es_DO_v2.idx -> th_es_ES_v2.idx
th_es_EC_v2.dat -> th_es_ES_v2.dat
th_es_EC_v2.idx -> th_es_ES_v2.idx
th_es_ES_v2.dat
th_es_ES_v2.idx
th_es_GT_v2.dat -> th_es_ES_v2.dat
th_es_GT_v2.idx -> th_es_ES_v2.idx
th_es_HN_v2.dat -> th_es_ES_v2.dat
th_es_HN_v2.idx -> th_es_ES_v2.idx
th_es_MX_v2.dat -> th_es_ES_v2.dat
th_es_MX_v2.idx -> th_es_ES_v2.idx
th_es_NI_v2.dat -> th_es_ES_v2.dat
th_es_NI_v2.idx -> th_es_ES_v2.idx
th_es_PA_v2.dat -> th_es_ES_v2.dat
th_es_PA_v2.idx -> th_es_ES_v2.idx
th_es_PE_v2.dat -> th_es_ES_v2.dat
th_es_PE_v2.idx -> th_es_ES_v2.idx
th_es_PR_v2.dat -> th_es_ES_v2.dat
th_es_PR_v2.idx -> th_es_ES_v2.idx
th_es_SV_v2.dat -> th_es_ES_v2.dat
th_es_SV_v2.idx -> th_es_ES_v2.idx
th_es_UY_v2.dat -> th_es_ES_v2.dat
th_es_UY_v2.idx -> th_es_ES_v2.idx
th_es_VE_v2.dat -> th_es_ES_v2.dat
th_es_VE_v2.idx -> th_es_ES_v2.idx
```

If you think it's necessary, I'll separate them too.
Comment by Juan Simón (j1simon) - Saturday, 30 June 2018, 09:47 GMT
The es_ANY is the compendium of all the other Spanish dictionaries.
Maybe the right thing to do would be to keep 'hunspell-es' but including only 'es_ANY'.

Loading...