Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
# Conflicts:
#	README.rst
#	setup.cfg
  • Loading branch information
jaraco committed Aug 28, 2022
2 parents 5865bea + 47c2cb3 commit e8de1a0
Show file tree
Hide file tree
Showing 14 changed files with 113 additions and 242 deletions.
5 changes: 4 additions & 1 deletion .coveragerc
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
[run]
omit = .tox/*
omit =
# leading `*/` for pytest-dev/pytest-cov#456
*/.tox/*
*/pep517-build-env-*

[report]
show_missing = True
19 changes: 19 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
root = true

[*]
charset = utf-8
indent_style = tab
indent_size = 4
insert_final_newline = true
end_of_line = lf

[*.py]
indent_style = space
max_line_length = 88

[*.{yml,yaml}]
indent_style = space
indent_size = 2

[*.rst]
indent_style = space
8 changes: 8 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
version: 2
updates:
- package-ecosystem: "pip"
directory: "/"
schedule:
interval: "daily"
allow:
- dependency-type: "all"
27 changes: 0 additions & 27 deletions .github/workflows/automerge.yml

This file was deleted.

39 changes: 30 additions & 9 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,32 +6,53 @@ jobs:
test:
strategy:
matrix:
python: [3.6, 3.8, 3.9]
platform: [ubuntu-latest, macos-latest, windows-latest]
python:
- 3.7
- '3.10'
- '3.11'
platform:
- ubuntu-latest
- macos-latest
- windows-latest
runs-on: ${{ matrix.platform }}
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Setup Python
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python }}
python-version: ${{ matrix.python }}-dev
- name: Install tox
run: |
python -m pip install tox
- name: Run tests
run: tox

check: # This job does nothing and is only used for the branch protection
if: always()

needs:
- test

runs-on: ubuntu-latest

steps:
- name: Decide whether the needed jobs succeeded or failed
uses: re-actors/alls-green@release/v1
with:
jobs: ${{ toJSON(needs) }}

release:
needs: test
needs:
- check
if: github.event_name == 'push' && contains(github.ref, 'refs/tags/')
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Setup Python
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: 3.9
python-version: "3.11-dev"
- name: Install tox
run: |
python -m pip install tox
Expand Down
7 changes: 1 addition & 6 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,10 +1,5 @@
repos:
- repo: https://github.com/psf/black
rev: 20.8b1
rev: 22.6.0
hooks:
- id: black

- repo: https://github.com/asottile/blacken-docs
rev: v1.9.1
hooks:
- id: blacken-docs
3 changes: 3 additions & 0 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@
.. image:: https://readthedocs.org/projects/jaracoclipboard/badge/?version=latest
:target: https://jaracoclipboard.readthedocs.io/en/latest/?badge=latest

.. image:: https://img.shields.io/badge/skeleton-2022-informational
:target: https://blog.jaraco.com/skeleton

The only clipboard library for Python that supports text on all
three major platforms plus HTML on MacOS and HTML and images
on Windows.
Expand Down
12 changes: 11 additions & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,18 @@
),
dict(
pattern=r'PEP[- ](?P<pep_number>\d+)',
url='https://www.python.org/dev/peps/pep-{pep_number:0>4}/',
url='https://peps.python.org/pep-{pep_number:0>4}/',
),
],
)
}

# Be strict about any broken references:
nitpicky = True

# Include Python intersphinx mapping to prevent failures
# jaraco/skeleton#51
extensions += ['sphinx.ext.intersphinx']
intersphinx_mapping = {
'python': ('https://docs.python.org/3', None),
}
10 changes: 5 additions & 5 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
[build-system]
requires = ["setuptools>=42", "wheel", "setuptools_scm[toml]>=3.4.1"]
requires = ["setuptools>=56", "setuptools_scm[toml]>=3.4.1"]
build-backend = "setuptools.build_meta"

[tool.black]
skip-string-normalization = true

[tool.setuptools_scm]

[pytest.enabler.black]
[tool.pytest-enabler.black]
addopts = "--black"

[pytest.enabler.mypy]
[tool.pytest-enabler.mypy]
addopts = "--mypy"

[pytest.enabler.flake8]
[tool.pytest-enabler.flake8]
addopts = "--flake8"

[pytest.enabler.cov]
[tool.pytest-enabler.cov]
addopts = "--cov"
16 changes: 12 additions & 4 deletions pytest.ini
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,16 @@
norecursedirs=dist build .tox .eggs
addopts=--doctest-modules
doctest_optionflags=ALLOW_UNICODE ELLIPSIS
# workaround for warning pytest-dev/pytest#6178
junit_family=xunit2
filterwarnings=
# https://github.com/pytest-dev/pytest/issues/6928
ignore:direct construction of .*Item has been deprecated:DeprecationWarning
# Suppress deprecation warning in flake8
ignore:SelectableGroups dict interface is deprecated::flake8

# shopkeep/pytest-black#55
ignore:<class 'pytest_black.BlackItem'> is not using a cooperative constructor:pytest.PytestDeprecationWarning
ignore:The \(fspath. py.path.local\) argument to BlackItem is deprecated.:pytest.PytestDeprecationWarning
ignore:BlackItem is an Item subclass and should not be a collector:pytest.PytestWarning

# tholo/pytest-flake8#83
ignore:<class 'pytest_flake8.Flake8Item'> is not using a cooperative constructor:pytest.PytestDeprecationWarning
ignore:The \(fspath. py.path.local\) argument to Flake8Item is deprecated.:pytest.PytestDeprecationWarning
ignore:Flake8Item is an Item subclass and should not be a collector:pytest.PytestWarning
30 changes: 17 additions & 13 deletions setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
[metadata]
license_files =
LICENSE
name = jaraco.clipboard
author = Jason R. Coombs
author_email = jaraco@jaraco.com
Expand All @@ -17,37 +15,43 @@ classifiers =
[options]
packages = find_namespace:
include_package_data = true
python_requires = >=3.6
python_requires = >=3.7
install_requires =
jaraco.windows >= 5.1; sys_platform=="win32"
richxerox >= 1.0.1; sys_platform=="darwin"
pyperclip >= 1.6; sys_platform=="linux2" or sys_platform=="linux"
setup_requires = setuptools_scm[toml] >= 3.4.1

[options.packages.find]
exclude =
build*
docs*
tests*
build*
dist*
docs*
tests*

[options.extras_require]
testing =
# upstream
pytest >= 3.5, !=3.7.3
pytest-checkdocs >= 1.2.3
pytest >= 6
pytest-checkdocs >= 2.4
pytest-flake8
pytest-black >= 0.3.7; python_implementation != "PyPy"
# workaround for tholo/pytest-flake8#87
flake8 < 5
pytest-black >= 0.3.7; \
# workaround for jaraco/skeleton#22
python_implementation != "PyPy"
pytest-cov
pytest-mypy; python_implementation != "PyPy"
pytest-enabler
pytest-mypy >= 0.9.1; \
# workaround for jaraco/skeleton#22
python_implementation != "PyPy"
pytest-enabler >= 1.3

# local
pygments

docs =
# upstream
sphinx
jaraco.packaging >= 8.2
jaraco.packaging >= 9
rst.linker >= 1.9

# local
Expand Down
6 changes: 0 additions & 6 deletions setup.py

This file was deleted.

0 comments on commit e8de1a0

Please sign in to comment.