diff options
| author | CoprDistGit <infra@openeuler.org> | 2023-05-18 07:28:13 +0000 |
|---|---|---|
| committer | CoprDistGit <infra@openeuler.org> | 2023-05-18 07:28:13 +0000 |
| commit | 218040e72e98962cddee04add4bd6d2b2b0cb291 (patch) | |
| tree | f5e23eb00049a4d1b21e1d194ae1e6cce336e2f3 /python-pyymatcher.spec | |
| parent | cac13fef5c0c1ca0bb71f2700b4c26f39b06cc52 (diff) | |
automatic import of python-pyymatcher
Diffstat (limited to 'python-pyymatcher.spec')
| -rw-r--r-- | python-pyymatcher.spec | 264 |
1 files changed, 264 insertions, 0 deletions
diff --git a/python-pyymatcher.spec b/python-pyymatcher.spec new file mode 100644 index 0000000..0691d5b --- /dev/null +++ b/python-pyymatcher.spec @@ -0,0 +1,264 @@ +%global _empty_manifest_terminate_build 0 +Name: python-pyymatcher +Version: 0.0.5 +Release: 1 +Summary: Implementation of pattern matching in Python(using gestalt approach) +License: MIT +URL: https://github.com/abdulniyaspm/pyymatcher +Source0: https://mirrors.nju.edu.cn/pypi/web/packages/03/10/8f7b2ff9b721096d4fe82e2d3cdb3ef136df1384f51edd79cd03f74d21f3/pyymatcher-0.0.5.tar.gz +BuildArch: noarch + + +%description +# PyyMatcher + +[](https://pypi.org/project/pyymatcher/) +[](https://pypi.org/project/pyymatcher/) +[](https://pypi.org/project/pyymatcher/) +[](https://github.com/ambv/black) + +> Implementation of pattern matching in Python(using gestalt approach). +> This library implements the underlaying algorithm(longest_common_substring) with C++. + +## Installation + +```python +pip install pyymatcher +``` + +## Usage example + +```python +>> from pyymatcher import PyyMatcher, get_close_matches + +>>> obj = PyyMatcher('Word1', 'word1') +>>> obj.ratio() +0.8 +>>> obj.ratio(case_insensitive=True) +1.0 +>>> obj.longest_common_substr +'ord1' + +>>> word = 'thiis' +>>> get_close_matches(word=word, + possibilities=['tthis', 'thhis', 'this', 'thiss', 'THIS'], + n=1) +['this'] +>>> get_close_matches(word=word, + possibilities=['tthis', 'thhis', 'this', 'thiss', 'THIS'], + n=2, + case_insensitive=True) +['this', 'THIS'] +``` + +## Release History + +* 0.0.1 + * initial release + +## Support + +Python 3.6+ + +## Meta + +Abdul Niyas P M – [@AbdulNiyas19](https://twitter.com/AbdulNiyas19) – abdulniyaspm@gmail.com + +Distributed under the MIT license. See ``LICENSE`` for more information. + +[Github Profile](https://github.com/abdulniyaspm) + +## Contributing + +1. Fork it (https://github.com/abdulniyaspm/pyymatcher/fork) +2. Create your feature branch (`git checkout -b feature/fooBar`) +3. Commit your changes (`git commit -am 'Add some fooBar'`) +4. Push to the branch (`git push origin feature/fooBar`) +5. Create a new Pull Request + +%package -n python3-pyymatcher +Summary: Implementation of pattern matching in Python(using gestalt approach) +Provides: python-pyymatcher +BuildRequires: python3-devel +BuildRequires: python3-setuptools +BuildRequires: python3-pip +%description -n python3-pyymatcher +# PyyMatcher + +[](https://pypi.org/project/pyymatcher/) +[](https://pypi.org/project/pyymatcher/) +[](https://pypi.org/project/pyymatcher/) +[](https://github.com/ambv/black) + +> Implementation of pattern matching in Python(using gestalt approach). +> This library implements the underlaying algorithm(longest_common_substring) with C++. + +## Installation + +```python +pip install pyymatcher +``` + +## Usage example + +```python +>> from pyymatcher import PyyMatcher, get_close_matches + +>>> obj = PyyMatcher('Word1', 'word1') +>>> obj.ratio() +0.8 +>>> obj.ratio(case_insensitive=True) +1.0 +>>> obj.longest_common_substr +'ord1' + +>>> word = 'thiis' +>>> get_close_matches(word=word, + possibilities=['tthis', 'thhis', 'this', 'thiss', 'THIS'], + n=1) +['this'] +>>> get_close_matches(word=word, + possibilities=['tthis', 'thhis', 'this', 'thiss', 'THIS'], + n=2, + case_insensitive=True) +['this', 'THIS'] +``` + +## Release History + +* 0.0.1 + * initial release + +## Support + +Python 3.6+ + +## Meta + +Abdul Niyas P M – [@AbdulNiyas19](https://twitter.com/AbdulNiyas19) – abdulniyaspm@gmail.com + +Distributed under the MIT license. See ``LICENSE`` for more information. + +[Github Profile](https://github.com/abdulniyaspm) + +## Contributing + +1. Fork it (https://github.com/abdulniyaspm/pyymatcher/fork) +2. Create your feature branch (`git checkout -b feature/fooBar`) +3. Commit your changes (`git commit -am 'Add some fooBar'`) +4. Push to the branch (`git push origin feature/fooBar`) +5. Create a new Pull Request + +%package help +Summary: Development documents and examples for pyymatcher +Provides: python3-pyymatcher-doc +%description help +# PyyMatcher + +[](https://pypi.org/project/pyymatcher/) +[](https://pypi.org/project/pyymatcher/) +[](https://pypi.org/project/pyymatcher/) +[](https://github.com/ambv/black) + +> Implementation of pattern matching in Python(using gestalt approach). +> This library implements the underlaying algorithm(longest_common_substring) with C++. + +## Installation + +```python +pip install pyymatcher +``` + +## Usage example + +```python +>> from pyymatcher import PyyMatcher, get_close_matches + +>>> obj = PyyMatcher('Word1', 'word1') +>>> obj.ratio() +0.8 +>>> obj.ratio(case_insensitive=True) +1.0 +>>> obj.longest_common_substr +'ord1' + +>>> word = 'thiis' +>>> get_close_matches(word=word, + possibilities=['tthis', 'thhis', 'this', 'thiss', 'THIS'], + n=1) +['this'] +>>> get_close_matches(word=word, + possibilities=['tthis', 'thhis', 'this', 'thiss', 'THIS'], + n=2, + case_insensitive=True) +['this', 'THIS'] +``` + +## Release History + +* 0.0.1 + * initial release + +## Support + +Python 3.6+ + +## Meta + +Abdul Niyas P M – [@AbdulNiyas19](https://twitter.com/AbdulNiyas19) – abdulniyaspm@gmail.com + +Distributed under the MIT license. See ``LICENSE`` for more information. + +[Github Profile](https://github.com/abdulniyaspm) + +## Contributing + +1. Fork it (https://github.com/abdulniyaspm/pyymatcher/fork) +2. Create your feature branch (`git checkout -b feature/fooBar`) +3. Commit your changes (`git commit -am 'Add some fooBar'`) +4. Push to the branch (`git push origin feature/fooBar`) +5. Create a new Pull Request + +%prep +%autosetup -n pyymatcher-0.0.5 + +%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-pyymatcher -f filelist.lst +%dir %{python3_sitelib}/* + +%files help -f doclist.lst +%{_docdir}/* + +%changelog +* Thu May 18 2023 Python_Bot <Python_Bot@openeuler.org> - 0.0.5-1 +- Package Spec generated |
