Accepting request 521554 from home:sebix
can maintain it - initial package for version 0.7.3 - add wip-pip.patch from upstream pull request #4 for setup.py - add allow_setup.py_call.patch allowing to use the setup.py file OBS-URL: https://build.opensuse.org/request/show/521554 OBS-URL: https://build.opensuse.org/package/show/utilities/mwic?expand=0&rev=1
This commit is contained in:
commit
1b92bc6336
23
.gitattributes
vendored
Normal file
23
.gitattributes
vendored
Normal file
@ -0,0 +1,23 @@
|
||||
## Default LFS
|
||||
*.7z filter=lfs diff=lfs merge=lfs -text
|
||||
*.bsp filter=lfs diff=lfs merge=lfs -text
|
||||
*.bz2 filter=lfs diff=lfs merge=lfs -text
|
||||
*.gem filter=lfs diff=lfs merge=lfs -text
|
||||
*.gz filter=lfs diff=lfs merge=lfs -text
|
||||
*.jar filter=lfs diff=lfs merge=lfs -text
|
||||
*.lz filter=lfs diff=lfs merge=lfs -text
|
||||
*.lzma filter=lfs diff=lfs merge=lfs -text
|
||||
*.obscpio filter=lfs diff=lfs merge=lfs -text
|
||||
*.oxt filter=lfs diff=lfs merge=lfs -text
|
||||
*.pdf filter=lfs diff=lfs merge=lfs -text
|
||||
*.png filter=lfs diff=lfs merge=lfs -text
|
||||
*.rpm filter=lfs diff=lfs merge=lfs -text
|
||||
*.tbz filter=lfs diff=lfs merge=lfs -text
|
||||
*.tbz2 filter=lfs diff=lfs merge=lfs -text
|
||||
*.tgz filter=lfs diff=lfs merge=lfs -text
|
||||
*.ttf filter=lfs diff=lfs merge=lfs -text
|
||||
*.txz filter=lfs diff=lfs merge=lfs -text
|
||||
*.whl filter=lfs diff=lfs merge=lfs -text
|
||||
*.xz filter=lfs diff=lfs merge=lfs -text
|
||||
*.zip filter=lfs diff=lfs merge=lfs -text
|
||||
*.zst filter=lfs diff=lfs merge=lfs -text
|
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
||||
.osc
|
26
allow_setup.py_call.patch
Normal file
26
allow_setup.py_call.patch
Normal file
@ -0,0 +1,26 @@
|
||||
--- setup.py 2017-09-05 22:16:11.104383219 +0200
|
||||
+++ setup.py 2017-09-05 22:45:17.009573847 +0200
|
||||
@@ -25,21 +25,18 @@
|
||||
Do not use directly.
|
||||
'''
|
||||
|
||||
-import distutils
|
||||
+import setuptools
|
||||
import glob
|
||||
import sys
|
||||
|
||||
... # Python 3 is required
|
||||
|
||||
-if 'setuptools' not in sys.modules:
|
||||
- raise RuntimeError(' '.join(__doc__.strip().splitlines()))
|
||||
-
|
||||
def get_version():
|
||||
with open('doc/changelog', 'rt', encoding='UTF-8') as file:
|
||||
line = file.readline()
|
||||
return line.split()[1].strip('()')
|
||||
|
||||
-distutils.core.setup(
|
||||
+setuptools.setup(
|
||||
name='mwic',
|
||||
version=get_version(),
|
||||
license='MIT License',
|
3
mwic-0.7.3.tar.gz
Normal file
3
mwic-0.7.3.tar.gz
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:f643b69f7f2ddd5c124e9f8ed6f04f1f5663d8bf39dd64c22425a9a5ec154a2d
|
||||
size 30468
|
6
mwic.changes
Normal file
6
mwic.changes
Normal file
@ -0,0 +1,6 @@
|
||||
-------------------------------------------------------------------
|
||||
Tue Sep 5 20:06:14 UTC 2017 - sebix+novell.com@sebix.at
|
||||
|
||||
- initial package for version 0.7.3
|
||||
- add wip-pip.patch from upstream pull request #4 for setup.py
|
||||
- add allow_setup.py_call.patch allowing to use the setup.py file
|
60
mwic.spec
Normal file
60
mwic.spec
Normal file
@ -0,0 +1,60 @@
|
||||
#
|
||||
# spec file for package mwic
|
||||
#
|
||||
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
# upon. The license for this file, and modifications and additions to the
|
||||
# file, is the same license as for the pristine package itself (unless the
|
||||
# license for the pristine package is not an Open Source License, in which
|
||||
# case the license is the MIT License). An "Open Source License" is a
|
||||
# license that conforms to the Open Source Definition (Version 1.9)
|
||||
# published by the Open Source Initiative.
|
||||
|
||||
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
||||
#
|
||||
|
||||
|
||||
%{!?license: %global license %doc}
|
||||
Name: mwic
|
||||
Version: 0.7.3
|
||||
Release: 0
|
||||
Summary: Misspelled Words In Context
|
||||
License: MIT
|
||||
Group: Productivity/Office/Other
|
||||
Url: http://jwilk.net/software/mwic
|
||||
Source: https://github.com/jwilk/mwic/releases/download/0.7.3/mwic-0.7.3.tar.gz
|
||||
# PATCH-FIX-UPSTREAM wip-pip.patch sebix+novell.com@sebix.at -- Allow installation with pip
|
||||
Patch0: https://github.com/jwilk/mwic/compare/wip/pip.patch#/wip-pip.patch
|
||||
# PATCH-FIX-OPENSUSE allow_setup.py_call.patch sebix+novell.com@sebix.at -- Allow direct call to setup.py
|
||||
Patch1: allow_setup.py_call.patch
|
||||
BuildRequires: python3-devel >= 3.2
|
||||
BuildRequires: python3-setuptools
|
||||
Requires: python3-pyenchant
|
||||
Requires: python3-regex
|
||||
BuildArch: noarch
|
||||
|
||||
%description
|
||||
mwic is a spell-checker that groups possible misspellings and shows them in their contexts. This is useful for checking technical documents that often contain words that are not included in standard dictionaries.
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
%patch0 -p1
|
||||
%patch1
|
||||
|
||||
%build
|
||||
python3 setup.py build
|
||||
|
||||
%install
|
||||
python3 setup.py install --prefix=%{_prefix} --root=%{buildroot}
|
||||
|
||||
%files
|
||||
%doc doc/changelog
|
||||
%license doc/LICENSE
|
||||
%{python3_sitelib}/*
|
||||
%{_bindir}/mwic
|
||||
%{_mandir}/man1/mwic.1%{?ext_man}
|
||||
|
||||
%changelog
|
||||
|
76
wip-pip.patch
Normal file
76
wip-pip.patch
Normal file
@ -0,0 +1,76 @@
|
||||
From 560987ccecfdb93a6abb458084abe92baa3b8ea3 Mon Sep 17 00:00:00 2001
|
||||
From: Jakub Wilk <jwilk@jwilk.net>
|
||||
Date: Tue, 30 May 2017 01:59:41 +0200
|
||||
Subject: [PATCH] setup: add.
|
||||
|
||||
---
|
||||
setup.py | 60 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
||||
1 file changed, 60 insertions(+)
|
||||
create mode 100644 setup.py
|
||||
|
||||
diff --git a/setup.py b/setup.py
|
||||
new file mode 100644
|
||||
index 0000000..69b8769
|
||||
--- /dev/null
|
||||
+++ b/setup.py
|
||||
@@ -0,0 +1,60 @@
|
||||
+# encoding=UTF-8
|
||||
+
|
||||
+# Copyright © 2016-2017 Jakub Wilk <jwilk@jwilk.net>
|
||||
+#
|
||||
+# Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
+# of this software and associated documentation files (the “Software”), to deal
|
||||
+# in the Software without restriction, including without limitation the rights
|
||||
+# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
+# copies of the Software, and to permit persons to whom the Software is
|
||||
+# furnished to do so, subject to the following conditions:
|
||||
+#
|
||||
+# The above copyright notice and this permission notice shall be included in
|
||||
+# all copies or substantial portions of the Software.
|
||||
+#
|
||||
+# THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
+# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
+# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
+# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
+# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
+# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
+# SOFTWARE.
|
||||
+
|
||||
+'''
|
||||
+This setup script is only for pip.
|
||||
+Do not use directly.
|
||||
+'''
|
||||
+
|
||||
+import distutils
|
||||
+import glob
|
||||
+import sys
|
||||
+
|
||||
+... # Python 3 is required
|
||||
+
|
||||
+if 'setuptools' not in sys.modules:
|
||||
+ raise RuntimeError(' '.join(__doc__.strip().splitlines()))
|
||||
+
|
||||
+def get_version():
|
||||
+ with open('doc/changelog', 'rt', encoding='UTF-8') as file:
|
||||
+ line = file.readline()
|
||||
+ return line.split()[1].strip('()')
|
||||
+
|
||||
+distutils.core.setup(
|
||||
+ name='mwic',
|
||||
+ version=get_version(),
|
||||
+ license='MIT License',
|
||||
+ description='Misspelled Words In Context',
|
||||
+ url='http://jwilk.net/software/mwic',
|
||||
+ author='Jakub Wilk',
|
||||
+ author_email='jwilk@jwilk.net',
|
||||
+ packages=['_mwic', '_mwic.lib'],
|
||||
+ package_dir={'_mwic': ''},
|
||||
+ package_data={'_mwic': ['dict/*']},
|
||||
+ data_files=[('share/man/man1', glob.glob('doc/*.1'))],
|
||||
+ entry_points=dict(
|
||||
+ console_scripts=['mwic = _mwic.lib.cli:main']
|
||||
+ ),
|
||||
+ install_requires=['pyenchant', 'regex'],
|
||||
+)
|
||||
+
|
||||
+# vim:ts=4 sts=4 sw=4 et
|
Loading…
x
Reference in New Issue
Block a user