diff options
| author | CoprDistGit <infra@openeuler.org> | 2023-05-17 03:00:08 +0000 |
|---|---|---|
| committer | CoprDistGit <infra@openeuler.org> | 2023-05-17 03:00:08 +0000 |
| commit | 4dd993353fea26b1d1ad8bb41a34456266ee1a61 (patch) | |
| tree | 3646d8b8bf564a295e04e764908caf7f1edac403 | |
| parent | 9ef3f6ecf8c8bfa88cdafdb97ef2ea3d72f54b17 (diff) | |
automatic import of python-pospell
| -rw-r--r-- | .gitignore | 1 | ||||
| -rw-r--r-- | python-pospell.spec | 336 | ||||
| -rw-r--r-- | sources | 1 |
3 files changed, 338 insertions, 0 deletions
@@ -0,0 +1 @@ +/pospell-1.1.tar.gz diff --git a/python-pospell.spec b/python-pospell.spec new file mode 100644 index 0000000..ee8b6c6 --- /dev/null +++ b/python-pospell.spec @@ -0,0 +1,336 @@ +%global _empty_manifest_terminate_build 0 +Name: python-pospell +Version: 1.1 +Release: 1 +Summary: Spellcheck .po files containing reStructuredText translations +License: MIT license +URL: https://github.com/AFPy/pospell +Source0: https://mirrors.nju.edu.cn/pypi/web/packages/7b/84/451e61b3d082c2a559d826b9c32e7a001115c715657b5b0bbbdcdc33ddb7/pospell-1.1.tar.gz +BuildArch: noarch + +Requires: python3-polib +Requires: python3-docutils +Requires: python3-regex + +%description +# pospell + +`pospell` is a spellcheckers for po files containing reStructuedText. + + +## Pospell is part of poutils! + +[Poutils](https://pypi.org/project/poutils) (`.po` utils) is a metapackage to easily install useful Python tools to use with po files +and `pospell` is a part of it! Go check out [Poutils](https://pypi.org/project/poutils) to discover the other tools! + + +## Examples + +By giving files to `pospell`: +``` +$ pospell --language fr about.po +about.po:47:Jr. +about.po:55:reStructuredText +about.po:55:Docutils +about.po:63:Fredrik +about.po:63:Lundh +about.po:75:language +about.po:75:librarie +``` + +By using a bash expansion (note that we do not put quotes around +`*.po` to let bash do its expansion): + +``` +$ pospell --language fr *.po +… +``` + +By using a glob pattern (note that we *do* put quotes around `**/*.po` +to keep your shell from trying to expand it, we'll let Python do the +expansion: + +``` +$ pospell --language fr --glob '**/*.po' +… +``` + + +## Usage + +``` +usage: pospell [-h] [-l LANGUAGE] [--glob GLOB] [--debug] [-p PERSONAL_DICT] + [po_file [po_file ...]] + +Check spelling in po files containing restructuredText. + +positional arguments: + po_file Files to check, can optionally be mixed with --glob, + or not, use the one that fit your needs. + +optional arguments: + -h, --help show this help message and exit + -l LANGUAGE, --language LANGUAGE + Language to check, you'll have to install the + corresponding hunspell dictionary, on Debian see apt + list 'hunspell-*'. + --glob GLOB Provide a glob pattern, to be interpreted by pospell, + to find po files, like --glob '**/*.po'. + --debug + -p PERSONAL_DICT, --personal-dict PERSONAL_DICT +``` + +A personal dict (the `-p` option) is simply a text file with one word +per line. + + +## Contributing + +You can work in a venv, to install the project locally: + +```bash +python -m pip install . +``` + +And to test it locally: + +```bash +python -m pip install tox +tox -p all +``` + + + + +%package -n python3-pospell +Summary: Spellcheck .po files containing reStructuredText translations +Provides: python-pospell +BuildRequires: python3-devel +BuildRequires: python3-setuptools +BuildRequires: python3-pip +%description -n python3-pospell +# pospell + +`pospell` is a spellcheckers for po files containing reStructuedText. + + +## Pospell is part of poutils! + +[Poutils](https://pypi.org/project/poutils) (`.po` utils) is a metapackage to easily install useful Python tools to use with po files +and `pospell` is a part of it! Go check out [Poutils](https://pypi.org/project/poutils) to discover the other tools! + + +## Examples + +By giving files to `pospell`: +``` +$ pospell --language fr about.po +about.po:47:Jr. +about.po:55:reStructuredText +about.po:55:Docutils +about.po:63:Fredrik +about.po:63:Lundh +about.po:75:language +about.po:75:librarie +``` + +By using a bash expansion (note that we do not put quotes around +`*.po` to let bash do its expansion): + +``` +$ pospell --language fr *.po +… +``` + +By using a glob pattern (note that we *do* put quotes around `**/*.po` +to keep your shell from trying to expand it, we'll let Python do the +expansion: + +``` +$ pospell --language fr --glob '**/*.po' +… +``` + + +## Usage + +``` +usage: pospell [-h] [-l LANGUAGE] [--glob GLOB] [--debug] [-p PERSONAL_DICT] + [po_file [po_file ...]] + +Check spelling in po files containing restructuredText. + +positional arguments: + po_file Files to check, can optionally be mixed with --glob, + or not, use the one that fit your needs. + +optional arguments: + -h, --help show this help message and exit + -l LANGUAGE, --language LANGUAGE + Language to check, you'll have to install the + corresponding hunspell dictionary, on Debian see apt + list 'hunspell-*'. + --glob GLOB Provide a glob pattern, to be interpreted by pospell, + to find po files, like --glob '**/*.po'. + --debug + -p PERSONAL_DICT, --personal-dict PERSONAL_DICT +``` + +A personal dict (the `-p` option) is simply a text file with one word +per line. + + +## Contributing + +You can work in a venv, to install the project locally: + +```bash +python -m pip install . +``` + +And to test it locally: + +```bash +python -m pip install tox +tox -p all +``` + + + + +%package help +Summary: Development documents and examples for pospell +Provides: python3-pospell-doc +%description help +# pospell + +`pospell` is a spellcheckers for po files containing reStructuedText. + + +## Pospell is part of poutils! + +[Poutils](https://pypi.org/project/poutils) (`.po` utils) is a metapackage to easily install useful Python tools to use with po files +and `pospell` is a part of it! Go check out [Poutils](https://pypi.org/project/poutils) to discover the other tools! + + +## Examples + +By giving files to `pospell`: +``` +$ pospell --language fr about.po +about.po:47:Jr. +about.po:55:reStructuredText +about.po:55:Docutils +about.po:63:Fredrik +about.po:63:Lundh +about.po:75:language +about.po:75:librarie +``` + +By using a bash expansion (note that we do not put quotes around +`*.po` to let bash do its expansion): + +``` +$ pospell --language fr *.po +… +``` + +By using a glob pattern (note that we *do* put quotes around `**/*.po` +to keep your shell from trying to expand it, we'll let Python do the +expansion: + +``` +$ pospell --language fr --glob '**/*.po' +… +``` + + +## Usage + +``` +usage: pospell [-h] [-l LANGUAGE] [--glob GLOB] [--debug] [-p PERSONAL_DICT] + [po_file [po_file ...]] + +Check spelling in po files containing restructuredText. + +positional arguments: + po_file Files to check, can optionally be mixed with --glob, + or not, use the one that fit your needs. + +optional arguments: + -h, --help show this help message and exit + -l LANGUAGE, --language LANGUAGE + Language to check, you'll have to install the + corresponding hunspell dictionary, on Debian see apt + list 'hunspell-*'. + --glob GLOB Provide a glob pattern, to be interpreted by pospell, + to find po files, like --glob '**/*.po'. + --debug + -p PERSONAL_DICT, --personal-dict PERSONAL_DICT +``` + +A personal dict (the `-p` option) is simply a text file with one word +per line. + + +## Contributing + +You can work in a venv, to install the project locally: + +```bash +python -m pip install . +``` + +And to test it locally: + +```bash +python -m pip install tox +tox -p all +``` + + + + +%prep +%autosetup -n pospell-1.1 + +%build +%py3_build + +%install +%py3_install +install -d -m755 %{buildroot}/%{_pkgdocdir} +if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi +if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi +if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi +if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi +pushd %{buildroot} +if [ -d usr/lib ]; then + find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/lib64 ]; then + find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/bin ]; then + find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/sbin ]; then + find usr/sbin -type f -printf "/%h/%f\n" >> filelist.lst +fi +touch doclist.lst +if [ -d usr/share/man ]; then + find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst +fi +popd +mv %{buildroot}/filelist.lst . +mv %{buildroot}/doclist.lst . + +%files -n python3-pospell -f filelist.lst +%dir %{python3_sitelib}/* + +%files help -f doclist.lst +%{_docdir}/* + +%changelog +* Wed May 17 2023 Python_Bot <Python_Bot@openeuler.org> - 1.1-1 +- Package Spec generated @@ -0,0 +1 @@ +9d58fe4faed8fddb6ea5e8c746bace17 pospell-1.1.tar.gz |
