diff --git a/.gitignore b/.gitignore index e69de29..5cb59d9 100644 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1 @@ +/kannada.oxt diff --git a/hunspell-kn.spec b/hunspell-kn.spec new file mode 100644 index 0000000..7879305 --- /dev/null +++ b/hunspell-kn.spec @@ -0,0 +1,90 @@ +Name: hunspell-kn +Summary: Kannada hunspell dictionaries +Version: 1.0.3 +Release: 20%{?dist} +Source: https://downloads.sourceforge.net/project/aoo-extensions/2628/1/kannada.oxt +URL: http://extensions.services.openoffice.org/project/kannada +License: GPLv2+ or LGPLv2+ or MPLv1.1 +BuildArch: noarch + +Requires: hunspell +Supplements: (hunspell and langpacks-kn) + +%description +Kannada hunspell dictionaries. + +%prep +%autosetup -c -n hunspell-kn + +%build + +%install +mkdir -p $RPM_BUILD_ROOT/%{_datadir}/myspell +cp -p kn_IN.* $RPM_BUILD_ROOT/%{_datadir}/myspell/ + +%files +%doc README_kn_IN.txt +%license COPYING COPYING.MPL COPYING.GPL COPYING.LGPL +%{_datadir}/myspell/* + +%changelog +* Tue Jul 28 2020 Fedora Release Engineering - 1.0.3-20 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild + +* Wed Jan 29 2020 Fedora Release Engineering - 1.0.3-19 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild + +* Thu Jul 25 2019 Fedora Release Engineering - 1.0.3-18 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild + +* Fri Feb 01 2019 Fedora Release Engineering - 1.0.3-17 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild + +* Fri Jul 13 2018 Fedora Release Engineering - 1.0.3-16 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild + +* Wed Feb 07 2018 Fedora Release Engineering - 1.0.3-15 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild + +* Thu Sep 28 2017 Parag Nemade - 1.0.3-14 +- spec cleanup + +* Wed Jul 26 2017 Fedora Release Engineering - 1.0.3-13 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild + +* Fri Feb 10 2017 Fedora Release Engineering - 1.0.3-12 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild + +* Fri Feb 19 2016 Parag Nemade - 1.0.3-11 +- Add Supplements: tag for langpacks naming guidelines +- Clean the specfile to follow current packaging guidelines + +* Thu Feb 04 2016 Fedora Release Engineering - 1.0.3-10 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild + +* Wed Jun 17 2015 Fedora Release Engineering - 1.0.3-9 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild + +* Sat Jun 07 2014 Fedora Release Engineering - 1.0.3-8 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild + +* Sat Aug 03 2013 Fedora Release Engineering - 1.0.3-7 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild + +* Thu Feb 14 2013 Fedora Release Engineering - 1.0.3-6 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild + +* Thu Jul 19 2012 Fedora Release Engineering - 1.0.3-5 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild + +* Fri Jan 13 2012 Fedora Release Engineering - 1.0.3-4 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild + +* Wed Feb 09 2011 Fedora Release Engineering - 1.0.3-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild + +* Fri Jul 24 2009 Fedora Release Engineering - 1.0.3-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild + +* Thu Jul 09 2009 Ramakrishna Reddy Yekulla - 1.0.3-1 +- initial version diff --git a/kannada.oxt b/kannada.oxt new file mode 100644 index 0000000..b059828 Binary files /dev/null and b/kannada.oxt differ diff --git a/sources b/sources new file mode 100644 index 0000000..cf01707 --- /dev/null +++ b/sources @@ -0,0 +1 @@ +SHA512 (kannada.oxt) = f92a88cd397c146a7b9a4e8ba4fbb7a60a5746b14362e5fc8a06ac01bcae66088bfefb6db777fa61b55b87404a46eb3fd44f7c58c88e25b3968a919d9542802b diff --git a/tests/scripts/run_tests.sh b/tests/scripts/run_tests.sh new file mode 100644 index 0000000..80d965a --- /dev/null +++ b/tests/scripts/run_tests.sh @@ -0,0 +1,4 @@ +#!/bin/bash + +python3 test_suggest_words.py +python3 test_dic_availability.py diff --git a/tests/scripts/test_dic_availability.py b/tests/scripts/test_dic_availability.py new file mode 100644 index 0000000..fe813a7 --- /dev/null +++ b/tests/scripts/test_dic_availability.py @@ -0,0 +1,10 @@ +#!/usr/bin/python3 + +import enchant + +lang = "hi_IN" +try: + dic = enchant.request_dict(lang) + print("Dictionary for {0} language is available for use".format(lang)) +except enchant.errors.DictNotFoundError: + print("Dictionary is not installed for use") diff --git a/tests/scripts/test_suggest_words.py b/tests/scripts/test_suggest_words.py new file mode 100644 index 0000000..b56bba2 --- /dev/null +++ b/tests/scripts/test_suggest_words.py @@ -0,0 +1,9 @@ +#!/usr/bin/python3 + +import enchant + +wdlst = [ "नमस", "तरका", "चायत"] +dic = enchant.Dict("hi_IN") +for wd in wdlst: + dic.check(wd) + print("input word = {0}, Suggestions => {1}".format(wd, dic.suggest(wd))) diff --git a/tests/tests.yml b/tests/tests.yml new file mode 100644 index 0000000..5ffb74a --- /dev/null +++ b/tests/tests.yml @@ -0,0 +1,11 @@ +- hosts: localhost + roles: + - role: standard-test-basic + required_packages: + - python3-enchant + tags: + - classic + tests: + - sample: + dir: scripts/ + run: ./run_tests.sh