Script 'mail_helper' called by obssrc
Hello community,
here is the log from the commit of package python-argparse-manpage for
openSUSE:Factory checked in at 2023-10-02 20:07:15
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-argparse-manpage (Old)
and /work/SRC/openSUSE:Factory/.python-argparse-manpage.new.28202 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-argparse-manpage"
Mon Oct 2 20:07:15 2023 rev:14 rq:1114782 version:4.5
Changes:
--------
---
/work/SRC/openSUSE:Factory/python-argparse-manpage/python-argparse-manpage.changes
2023-06-15 11:45:25.201404734 +0200
+++
/work/SRC/openSUSE:Factory/.python-argparse-manpage.new.28202/python-argparse-manpage.changes
2023-10-02 20:10:04.578593778 +0200
@@ -1,0 +2,11 @@
+Mon Oct 2 09:23:46 UTC 2023 - Dirk Müller <[email protected]>
+
+- update to 4.5:
+ * We newly provide build_manpages.build_py and build_manpages.install
+ command classes that are re-usable from pyproject.toml.
+ No need to provide setup.py because of argparse-manpage.
+ * The prog= specifier (in setup.py/setup.cfg/pyproject.toml) is
+ now better handled so it doesn't conflict with
+ ArgumentParser(prog=..).
+
+-------------------------------------------------------------------
Old:
----
v4.3.tar.gz
New:
----
v4.5.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-argparse-manpage.spec ++++++
--- /var/tmp/diff_new_pack.wtUQkD/_old 2023-10-02 20:10:05.642632043 +0200
+++ /var/tmp/diff_new_pack.wtUQkD/_new 2023-10-02 20:10:05.642632043 +0200
@@ -18,7 +18,7 @@
%define mod_name argparse-manpage
Name: python-argparse-manpage
-Version: 4.3
+Version: 4.5
Release: 0
Summary: Tool for automatic manual page building from a Python
ArgumentParser object
License: Apache-2.0
++++++ v4.3.tar.gz -> v4.5.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/argparse-manpage-4.3/NEWS
new/argparse-manpage-4.5/NEWS
--- old/argparse-manpage-4.3/NEWS 2023-05-17 15:02:31.000000000 +0200
+++ new/argparse-manpage-4.5/NEWS 2023-09-22 22:22:41.000000000 +0200
@@ -5,6 +5,21 @@
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+News in v4.5
+
+* We newly provide `build_manpages.build_py` and `build_manpages.install`
+ command classes that are re-usable from `pyproject.toml`. No need to
+ provide `setup.py` because of `argparse-manpage`. Solved issue#85.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+News in v4.4
+
+* The `prog=` specifier (in setup.py/setup.cfg/pyproject.toml) is now
+ better handled so it doesn't conflict with ArgumentParser(prog=..).
+ Fixes https://github.com/praiskup/argparse-manpage/issues/79
+
+
News in v4.3
* The pyproject.toml parsing feature now depends on the python3-tomli library
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/argparse-manpage-4.3/README.md
new/argparse-manpage-4.5/README.md
--- old/argparse-manpage-4.3/README.md 2023-05-17 15:02:31.000000000 +0200
+++ new/argparse-manpage-4.5/README.md 2023-09-22 22:22:41.000000000 +0200
@@ -47,18 +47,19 @@
variable.
-## Use with setup.py
+## Use with pyproject.toml
-First, you need to declare that `setup.py` uses an external package in your
-`pyproject.toml` file:
+First, you need to declare in `pyproject.toml` that argparse-manpage is needed
+at build-time and use the setuptools.builds_meta` backend:
```toml
[build-system]
requires = ["argparse-manpage[setuptools]"]
+build-backend = "setuptools.build_meta"
```
-Alternatively you can place the `build_manpages` (sub)directory from this
-project somewhere onto `PYTHONPATH` so you can use it in `setup.py`. For
+Alternatively, you can place the `build_manpages` (sub)directory from this
+project somewhere onto `PYTHONPATH` so you can use it at build time. For
example:
```bash
@@ -66,6 +67,28 @@
git submodule update --init
```
+Then in `pyproject.toml` (re)define `cmdclass` commands:
+
+```toml
+[tool.setuptools.cmdclass]
+build_py = "build_manpages.build_py"
+install = "build_manpages.install"
+build_manpages = "build_manpages.build_manpages"
+```
+
+And specify the list of built manual pages:
+
+```toml
+[tool.build_manpages]
+manpages = [
+ "man/foo.1:object=parser:pyfile=bin/foo.py",
+ "man/bar.1:function=get_parser:pyfile=bin/bar",
+ "man/baz.1:function=get_parser:pyfile=bin/bar:prog=baz",
+]
+```
+
+## Use with setup.py
+
In your `setup.py` use pattern like:
```python
@@ -95,16 +118,7 @@
man/baz.1:function=get_parser:pyfile=bin/bar:prog=baz
```
-Or in `pyproject.toml` (requires setuptools >= 62.2.0):
-
-```toml
-[build_manpages]
-manpages = [
- "man/foo.1:object=parser:pyfile=bin/foo.py",
- "man/bar.1:function=get_parser:pyfile=bin/bar",
- "man/baz.1:function=get_parser:pyfile=bin/bar:prog=baz",
-]
-```
+## List of manual pages
The format of those lines is a colon separated list of arguments/options. The
first argument determines the filename of the generated manual page. Then
@@ -127,6 +141,7 @@
see man (7) man-pages for more instructions
- include - a file of extra material to include; see below for the format
- manfile - a file containing a complete man page that just needs to be
installed
+ (such files must also be listed in `MANIFEST.in`)
The values from setup.cfg override values from setup.py's setup(). Note that
when `manfile` is set for a particular page, no other option is allowed.
@@ -183,7 +198,7 @@
The `argparse-manpage` project is provided natively on many distributions:
-
+
Try your package manager directly (e.g. on Fedora `dnf install -y
argparse-manpage`).
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/argparse-manpage-4.3/argparse_manpage/__init__.py
new/argparse-manpage-4.5/argparse_manpage/__init__.py
--- old/argparse-manpage-4.3/argparse_manpage/__init__.py 2023-05-17
15:02:31.000000000 +0200
+++ new/argparse-manpage-4.5/argparse_manpage/__init__.py 2023-09-22
22:22:41.000000000 +0200
@@ -2,4 +2,4 @@
argparse_manpage project
"""
-__version__ = '4.3'
+__version__ = '4.5'
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/argparse-manpage-4.3/argparse_manpage/manpage.py
new/argparse-manpage-4.5/argparse_manpage/manpage.py
--- old/argparse-manpage-4.3/argparse_manpage/manpage.py 2023-05-17
15:02:31.000000000 +0200
+++ new/argparse-manpage-4.5/argparse_manpage/manpage.py 2023-09-22
22:22:41.000000000 +0200
@@ -169,7 +169,7 @@
self.formatter = self.parser._get_formatter()
self.mf = _ManpageFormatter(self.prog, self.formatter,
format=self.format)
- self.synopsis = self.parser.format_usage().split(':')[-1].split()
+ self.synopsis = self.parser.format_usage().split(':', 1)[-1].split()
self.date = self._data.get("date")
if not self.date:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/argparse-manpage-4.3/build_manpages/__init__.py
new/argparse-manpage-4.5/build_manpages/__init__.py
--- old/argparse-manpage-4.3/build_manpages/__init__.py 2023-05-17
15:02:31.000000000 +0200
+++ new/argparse-manpage-4.5/build_manpages/__init__.py 2023-09-22
22:22:41.000000000 +0200
@@ -4,3 +4,6 @@
from argparse_manpage import __version__
from .build_manpages import build_manpages, get_build_py_cmd, get_install_cmd
+
+install = get_install_cmd()
+build_py = get_build_py_cmd()
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/argparse-manpage-4.3/build_manpages/build_manpages.py
new/argparse-manpage-4.5/build_manpages/build_manpages.py
--- old/argparse-manpage-4.3/build_manpages/build_manpages.py 2023-05-17
15:02:31.000000000 +0200
+++ new/argparse-manpage-4.5/build_manpages/build_manpages.py 2023-09-22
22:22:41.000000000 +0200
@@ -39,6 +39,8 @@
for spec in string.strip().split('\n'):
manpagedata = {}
output = True
+
+ basename = None
for option in spec.split(':'):
if output:
outputfile = option
@@ -57,7 +59,7 @@
manpagedata['import_type'] = oname
manpagedata['import_from'] = ovalue
if oname == 'pyfile':
- manpagedata['prog'] = os.path.basename(ovalue)
+ basename = os.path.basename(ovalue)
elif oname == 'format':
assert(not 'format' in manpagedata)
@@ -73,6 +75,9 @@
else:
raise ValueError("Unknown manpage configuration option:
{}".format(oname))
+ if "prog" not in manpagedata and basename:
+ manpagedata["prog"] = basename
+
manpages_data[outputfile] = manpagedata
return manpages_data
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/argparse-manpage-4.3/rpm/argparse-manpage.spec.tpl
new/argparse-manpage-4.5/rpm/argparse-manpage.spec.tpl
--- old/argparse-manpage-4.3/rpm/argparse-manpage.spec.tpl 2023-05-17
15:02:31.000000000 +0200
+++ new/argparse-manpage-4.5/rpm/argparse-manpage.spec.tpl 2023-09-22
22:22:41.000000000 +0200
@@ -32,7 +32,7 @@
Summary: %{sum Python}
BuildArch: noarch
-License: ASL 2.0
+License: Apache-2.0
URL: https://github.com/praiskup/%{name}
Source0:
https://github.com/praiskup/%{name}/archive/v%{version}/%{name}-%{version}.tar.gz
@@ -80,6 +80,7 @@
%package -n python2-%name
Summary: %{sum Python 2}
Requires: python2-setuptools
+Requires: python2-toml
%description -n python2-%name
%{desc}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/argparse-manpage-4.3/setup.py
new/argparse-manpage-4.5/setup.py
--- old/argparse-manpage-4.3/setup.py 2023-05-17 15:02:31.000000000 +0200
+++ new/argparse-manpage-4.5/setup.py 2023-09-22 22:22:41.000000000 +0200
@@ -30,7 +30,7 @@
name='argparse-manpage',
version=__version__,
url='https://github.com/praiskup/argparse-manpage',
- license='Apache 2.0',
+ license='Apache-2.0',
author='Gabriele Giammatteo',
author_email='[email protected]',
maintainer='Pavel Raiskup',