Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable development & releasing tools from darkgray-dev-tools #23

Merged
merged 8 commits into from
Apr 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 22 additions & 8 deletions CHANGES.rst
Original file line number Diff line number Diff line change
@@ -1,9 +1,17 @@
Upcoming
========
Unreleased_
===========

These features will be included in the next release:

1.0.0 / 2021-09-11
===================
Added
-----

Fixed
-----


1.0.0_ / 2021-09-11
====================

Added
-----
Expand All @@ -16,17 +24,17 @@ Added
- ``pg_split_schema_dump.py`` for splitting a schema-only dump into multiple SQL files


0.9.1 / 2015-03-10
==================
0.9.1_ / 2015-03-10
===================

Added
-----

Document ``pg_incremental_backup.py`` in the README file


0.9 / 2015-03-10
================
0.9_ / 2015-03-10
=================

Added
-----
Expand All @@ -36,3 +44,9 @@ Added
- The New (3-clause) BSD license
- Unit tests, a ``setup.py`` script and a README file with a usage example
- ``pg_dump_splitsort.py`` for sorting and splitting ``pg_dump`` output


.. _Unreleased: https://github.com/akaihola/pgtricks/compare/1.0.0...HEAD
.. _1.0.0: https://github.com/akaihola/pgtricks/compare/0.9.1...1.0.0
.. _0.9.1: https://github.com/akaihola/pgtricks/compare/0.9...0.9.1
.. _0.9: https://github.com/akaihola/pgtricks/compare/46e4cdb...0.9
20 changes: 17 additions & 3 deletions CONTRIBUTORS.rst
Original file line number Diff line number Diff line change
@@ -1,5 +1,19 @@
==============================
Contributors to ``pgtricks``
==============================
==========================
Contributors to Pgtricks
==========================

(in alphabetic order and with GitHub handles)

.. This file is automatically generated. Please update ``contributors.yaml``
instead and see ``CONTRIBUTING.rst`` for instructions on how to update
this file.

- Albert Cai (@oldcai)
- Antti Kaihola (@akaihola)
- Connor Sherson (@connorsherson)
- Jonathan (@jomonson)
- Jose Luis (@jescobar87)
- mihuman (@mihuman)
- Phil Ayres (@philayres)
- Seweryn Niemiec (@thugcee)
- tyctor (@tyctor)
127 changes: 127 additions & 0 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@
.. _pypi-badge: https://pypi.org/project/pgtricks/
.. |downloads-badge| image:: https://pepy.tech/badge/pgtricks
.. _downloads-badge: https://pepy.tech/project/pgtricks
.. |next-milestone| image:: https://img.shields.io/github/milestones/progress/akaihola/pgtricks/1?color=red&label=release%201.0.1
:alt: Next milestone
:target: https://github.com/akaihola/pgtricks/milestone/1

This package contains two tools for backing up PostgreSQL database dumps.

Expand Down Expand Up @@ -97,3 +100,127 @@ Usage::
optional arguments:
-h, --help show this help message and exit
--output-dir OUTPUT_DIR, -o OUTPUT_DIR


Contributors ✨
===============

Thanks goes to these wonderful people (`emoji key`_):

.. raw:: html

<!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section
This is automatically generated. Please update `contributors.yaml` and
see `CONTRIBUTING.rst` for how to re-generate this table. -->
<table>
<tr>
<td align="center">
<a href="https://github.com/oldcai">
<img src="https://avatars.githubusercontent.com/u/1150130?v=3" width="100px;" alt="@oldcai" />
<br />
<sub>
<b>Albert Cai</b>
</sub>
</a>
<br />
<a href="https://github.com/akaihola/pgtricks/issues?q=author%3Aoldcai" title="Bug reports">🐛</a>
</td>
<td align="center">
<a href="https://github.com/akaihola">
<img src="https://avatars.githubusercontent.com/u/13725?v=3" width="100px;" alt="@akaihola" />
<br />
<sub>
<b>Antti Kaihola</b>
</sub>
</a>
<br />
<a href="https://github.com/akaihola/pgtricks/pulls?q=is%3Apr+author%3Aakaihola" title="Code">💻</a>
</td>
<td align="center">
<a href="https://github.com/connorsherson">
<img src="https://avatars.githubusercontent.com/u/59890055?v=3" width="100px;" alt="@connorsherson" />
<br />
<sub>
<b>Connor Sherson</b>
</sub>
</a>
<br />
<a href="https://github.com/akaihola/pgtricks/pulls?q=is%3Apr+author%3Aconnorsherson" title="Code">💻</a>
</td>
<td align="center">
<a href="https://github.com/jomonson">
<img src="https://avatars.githubusercontent.com/u/5840967?v=3" width="100px;" alt="@jomonson" />
<br />
<sub>
<b>Jonathan</b>
</sub>
</a>
<br />
<a href="https://github.com/akaihola/pgtricks/pulls?q=is%3Apr+author%3Ajomonson" title="Code">💻</a>
</td>
<td align="center">
<a href="https://github.com/jescobar87">
<img src="https://avatars.githubusercontent.com/u/4821014?v=3" width="100px;" alt="@jescobar87" />
<br />
<sub>
<b>Jose Luis</b>
</sub>
</a>
<br />
<a href="https://github.com/akaihola/pgtricks/issues?q=author%3Ajescobar87" title="Bug reports">🐛</a>
</td>
<td align="center">
<a href="https://github.com/philayres">
<img src="https://avatars.githubusercontent.com/u/294874?v=3" width="100px;" alt="@philayres" />
<br />
<sub>
<b>Phil Ayres</b>
</sub>
</a>
<br />
<a href="https://github.com/akaihola/pgtricks/issues?q=author%3Aphilayres" title="Bug reports">🐛</a>
</td>
</tr>
<tr>
<td align="center">
<a href="https://github.com/thugcee">
<img src="https://avatars.githubusercontent.com/u/20202?v=3" width="100px;" alt="@thugcee" />
<br />
<sub>
<b>Seweryn Niemiec</b>
</sub>
</a>
<br />
<a href="https://github.com/akaihola/pgtricks/issues?q=author%3Athugcee" title="Bug reports">🐛</a>
</td>
<td align="center">
<a href="https://github.com/mihuman">
<img src="https://avatars.githubusercontent.com/u/16466143?v=3" width="100px;" alt="@mihuman" />
<br />
<sub>
<b>mihuman</b>
</sub>
</a>
<br />
<a href="https://github.com/akaihola/pgtricks/pulls?q=is%3Apr+author%3Amihuman" title="Code">💻</a>
</td>
<td align="center">
<a href="https://github.com/tyctor">
<img src="https://avatars.githubusercontent.com/u/44854182?v=3" width="100px;" alt="@tyctor" />
<br />
<sub>
<b>tyctor</b>
</sub>
</a>
<br />
<a href="https://github.com/akaihola/pgtricks/issues?q=author%3Atyctor" title="Bug reports">🐛</a>
</td>
</tr>
</table> <!-- ALL-CONTRIBUTORS-LIST:END -->

This project follows the all-contributors_ specification.
Contributions of any kind are welcome!

.. _README.rst: https://github.com/akaihola/pgtricks/blob/master/README.rst
.. _emoji key: https://allcontributors.org/docs/en/emoji-key
.. _all-contributors: https://allcontributors.org
19 changes: 19 additions & 0 deletions contributors.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
---
akaihola:
- {link_type: pulls-author, type: Code}
connorsherson:
- {link_type: pulls-author, type: Code}
jescobar87:
- {link_type: issues, type: Bug reports}
jomonson:
- {link_type: pulls-author, type: Code}
mihuman:
- {link_type: pulls-author, type: Code}
oldcai:
- {link_type: issues, type: Bug reports}
philayres:
- {link_type: issues, type: Bug reports}
thugcee:
- {link_type: issues, type: Bug reports}
tyctor:
- {link_type: issues, type: Bug reports}
3 changes: 3 additions & 0 deletions pgtricks/version.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
"""The version number for Pgtricks is governed by this file."""

__version__ = "1.0.0"
29 changes: 29 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
[build-system]
# Minimum requirements for the build system to execute.
requires = ["setuptools", "wheel"] # PEP 508 specifications.

[tool.ruff]
target-version = "py38"

[tool.ruff.lint]
select = ["ALL"]
ignore = [
#"A002", # builtin-argument-shadowing
"ANN101", # Missing type annotation for `self` in method
"D203", # One blank line required before class docstring
"D213", # Multi-line docstring summary should start at the second line
#"D400", # First line should end with a period (duplicates D415)
]

[tool.ruff.lint.per-file-ignores]
"pgtricks/tests/*.py" = [
"ANN001", # Missing type annotation for function argument
"ANN201", # Missing return type annotation for public function
#"ANN204", # Missing return type annotation for special method `__init__`
#"C408", # Unnecessary `dict` call (rewrite as a literal)
"S101", # Use of `assert` detected
]

[tool.ruff.lint.isort]
known-first-party = ["pgtricks"]
known-third-party = ["pytest"]
38 changes: 38 additions & 0 deletions release_tools/bump-version-patterns.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
---

# Below are the regular expression patterns for finding and replacing version and
# milestone numbers in files. Keys are file paths relative to the repository root.
# Values are sets of regular expression pattern strings which contain a magic
# `{OLD->NEW}` expression. For matching text, that expression will be turned into a
# regular expression string which matches the expected version or milestone string in
# the current content of a file. For replacing those matches with updated information,
# `NEW` specifies which kind of a version or milestone number should be used as the
# replacement.
#
# For example, if the current version ("old_version") was `1.0.1` and bumping the minor
# version was requested, the entry
#
# "README.rst":
# - |-
# next version: {old_version->new_version}
#
# would use this regular expression:
#
# `r"next version: (1\.0\.1)"`
#
# in `README.rst` and replace the text matched by the capture group with "1.1".


"README.rst":
- |-
^ :target: https://github\.com/akaihola/pgtricks/milestone/{any_milestone->next_milestone}

- |-
^\.\. \|next-milestone\| image:: https://img\.shields\.io/github/milestones/progress/akaihola/pgtricks/{any_milestone->next_milestone}

- |-
label=release%20{any_version->next_version}

"pgtricks/version.py":
- |-
^__version__ *= *\"{old_version->new_version}\"
4 changes: 3 additions & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[metadata]
name = pgtricks
version = 1.0.1.dev0
version = attr: pgtricks.version.__version__
author = Antti Kaihola
author_email = [email protected]
license = BSD
Expand Down Expand Up @@ -48,6 +48,8 @@ test =
pylint
pytest
pytest-mypy
release =
darkgray-dev-tools~=0.0.2

[flake8]
max-line-length = 88
Expand Down
Loading