14
0

Accepting request 509673 from devel:languages:python

1

OBS-URL: https://build.opensuse.org/request/show/509673
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-sqlparse?expand=0&rev=5
This commit is contained in:
2017-09-05 13:14:25 +00:00
committed by Git OBS Bridge
4 changed files with 50 additions and 39 deletions

View File

@@ -1,3 +1,28 @@
-------------------------------------------------------------------
Wed Jul 12 05:40:09 UTC 2017 - tbechtold@suse.com
- update to 0.2.3:
* New command line option "--encoding" (by twang2218, pr317).
* Support CONCURRENTLY keyword (issue322, by rowanseymour).
* Fix some edge-cases when parsing invalid SQL statements.
* Fix indentation of LIMIT (by romainr, issue320).
* Fix parsing of INTO keyword (issue324).
* Several improvements regarding encodings.
* Add comma_first option: When splitting list "comma first" notation
is used (issue141).
* Fix parsing of incomplete AS (issue284, by vmuriart).
* Fix parsing of Oracle names containing dollars (issue291).
* Fix parsing of UNION ALL (issue294).
* Fix grouping of identifiers containing typecasts (issue297).
* Add Changelog to sdist again (issue302).
* `is_whitespace` and `is_group` changed into properties
- convert to singlespec
-------------------------------------------------------------------
Tue Nov 15 10:13:47 UTC 2016 - dmueller@suse.com
- update to 0.2.1
-------------------------------------------------------------------
Wed May 13 16:39:54 UTC 2015 - benoit.monin@gmx.fr

View File

@@ -1,7 +1,7 @@
#
# spec file for package python-sqlparse
#
# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
# 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
@@ -16,26 +16,25 @@
#
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
Name: python-sqlparse
Version: 0.1.15
Version: 0.2.3
Release: 0
Summary: Non-validating SQL parser
License: BSD-3-Clause
Group: Development/Languages/Python
Url: https://github.com/andialbrecht/sqlparse
Source: https://pypi.python.org/packages/source/s/sqlparse/sqlparse-%{version}.tar.gz
Source: https://files.pythonhosted.org/packages/source/s/sqlparse/sqlparse-%{version}.tar.gz
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildRequires: python-devel
BuildRequires: python-setuptools
# Test requirements:
BuildRequires: python-pytest
BuildRequires: %{python_module devel}
BuildRequires: %{python_module pytest}
BuildRequires: %{python_module setuptools}
BuildRequires: python-rpm-macros
Requires(post): update-alternatives
Requires(postun): update-alternatives
%if 0%{?suse_version} && 0%{?suse_version} <= 1110
%{!?python_sitelib: %global python_sitelib %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
%else
BuildArch: noarch
%endif
%python_subpackages
%description
sqlparse is a non-validating SQL parser module. It provides support for
@@ -43,40 +42,27 @@ parsing, splitting and formatting SQL statements.
%prep
%setup -q -n sqlparse-%{version}
sed -i "s|\(bin/sqlformat\)|\1-%{py_ver}|" setup.py
mv bin/sqlformat{,-%{py_ver}}
%build
python setup.py build
%python_build
%install
python setup.py install --prefix=%{_prefix} --root=%{buildroot}
ln -s %{_bindir}/sqlformat-%{py_ver} %{buildroot}%{_bindir}/sqlformat
%check
py.test tests
%pre
# Since /usr/bin/sqlformat became ghosted to be used with update-alternatives, we have
# to get rid of the old binary resulting from the non-update-alternativies-ified package:
[ -h %{_bindir}/sqlformat ] || rm -f %{_bindir}/sqlformat
%python_install
%python_clone -a %{buildroot}%{_bindir}/sqlformat
%post
update-alternatives --install %{_bindir}/sqlformat sqlformat %{_bindir}/sqlformat-%{py_ver} 20
%python_install_alternative sqlformat
%preun
if [ $1 -eq 0 ] ; then
update-alternatives --remove sphinx-build %{_bindir}/sqlformat-%{py_ver}
fi
%postun
%python_uninstall_alternative sqlformat
%files
%check
%python_exec %{_bindir}/py.test tests
%files %{python_files}
%defattr(-,root,root,-)
%doc COPYING AUTHORS CHANGES README.rst
%ghost %{_bindir}/sqlformat
%if 0%{?suse_version} >= 1230
%ghost %{_sysconfdir}/alternatives/sqlformat
%endif
%{_bindir}/sqlformat-%{py_ver}
%doc AUTHORS README.rst
%python_alternative %{_bindir}/sqlformat
%{python_sitelib}/*
%changelog

View File

@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:ce92c9f134b1cd461a27c502197464b5f245261ad0fbb26d7bf659f28a5c11b2
size 57863

3
sqlparse-0.2.3.tar.gz Normal file
View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:becd7cc7cebbdf311de8ceedfcf2bd2403297024418801947f8c953025beeff8
size 60742