From 3deb0d01d787585124aa02795e01330b5d3e174f Mon Sep 17 00:00:00 2001 From: chfw Date: Mon, 11 Nov 2024 08:37:07 +0000 Subject: [PATCH] :books: update project metadata --- .github/workflows/lint.yml | 4 ++-- .github/workflows/moban-update.yml | 8 ++++---- .github/workflows/pythonpublish.yml | 19 ++++++++++++------- .github/workflows/tests.yml | 25 ++++++++++++++----------- CONTRIBUTORS.rst | 8 +++++--- LICENSE | 4 ++-- README.rst | 12 ++++-------- 7 files changed, 43 insertions(+), 37 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 03122a1..3789494 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -14,7 +14,7 @@ jobs: python-version: 3.8 - name: lint run: | - pip install flake8 - pip install -r tests/requirements.txt + pip --use-deprecated=legacy-resolver install flake8 + pip --use-deprecated=legacy-resolver install -r tests/requirements.txt flake8 --exclude=.moban.d,docs,setup.py --builtins=unicode,xrange,long . python setup.py checkdocs diff --git a/.github/workflows/moban-update.yml b/.github/workflows/moban-update.yml index 706fd82..4038e3d 100644 --- a/.github/workflows/moban-update.yml +++ b/.github/workflows/moban-update.yml @@ -8,22 +8,22 @@ jobs: - uses: actions/checkout@v2 with: ref: ${{ github.head_ref }} + token: ${{ secrets.PAT }} - name: Set up Python uses: actions/setup-python@v1 with: python-version: '3.7' - name: check changes run: | + pip install markupsafe==2.0.1 pip install moban gitfs2 pypifs moban-jinja2-github moban-ansible moban git status git diff --exit-code - name: Auto-commit if: failure() - uses: docker://cdssnc/auto-commit-github-action - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + uses: stefanzweifel/git-auto-commit-action@v4 with: - args: >- + commit_message: >- This is an auto-commit, updating project meta data, such as changelog.rst, contributors.rst diff --git a/.github/workflows/pythonpublish.yml b/.github/workflows/pythonpublish.yml index 9e7ec42..4ccaa8d 100644 --- a/.github/workflows/pythonpublish.yml +++ b/.github/workflows/pythonpublish.yml @@ -5,9 +5,16 @@ on: types: [created] jobs: - deploy: + pypi-publish: + name: upload release to PyPI runs-on: ubuntu-latest + # Specifying a GitHub environment is optional, but strongly encouraged + environment: pypi + permissions: + # IMPORTANT: this permission is mandatory for trusted publishing + id-token: write steps: + # retrieve your distributions here - uses: actions/checkout@v1 - name: Set up Python uses: actions/setup-python@v1 @@ -16,11 +23,9 @@ jobs: - name: Install dependencies run: | python -m pip install --upgrade pip - pip install setuptools wheel twine - - name: Build and publish - env: - TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }} - TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }} + pip install setuptools wheel + - name: Build run: | python setup.py sdist bdist_wheel - twine upload dist/* + - name: Publish package distributions to PyPI + uses: pypa/gh-action-pypi-publish@release/v1 diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index b1dac13..c004ba3 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -1,27 +1,30 @@ -name: run_tests +name: Run unit tests on Windows, Ubuntu and Mac on: [push, pull_request] jobs: + test: + name: ${{ matrix.os }} / ${{ matrix.python_version }} + runs-on: ${{ matrix.os }}-latest strategy: - fail-fast: false - matrix: - python-version: [3.6, 3.7, 3.8, 3.9] - os: [macOs-latest, ubuntu-latest, windows-latest] + fail-fast: false + matrix: + os: [Ubuntu] + python_version: ["3.9.16"] - runs-on: ${{ matrix.os }} - name: run tests steps: - uses: actions/checkout@v2 - name: Set up Python - uses: actions/setup-python@v1 + uses: actions/setup-python@v5 with: - python-version: ${{ matrix.python-version }} + python-version: ${{ matrix.python_version }} + architecture: x64 + - name: install run: | - pip install -r requirements.txt - pip install -r tests/requirements.txt + pip --use-deprecated=legacy-resolver install -r requirements.txt + pip --use-deprecated=legacy-resolver install -r tests/requirements.txt - name: test run: | pip freeze diff --git a/CONTRIBUTORS.rst b/CONTRIBUTORS.rst index 423f980..16c04e4 100644 --- a/CONTRIBUTORS.rst +++ b/CONTRIBUTORS.rst @@ -1,6 +1,8 @@ -No contributors yet -======================= +1 contributors +================================================================================ -* Your github link will be listed here after your PR is merged +In alphabetical order: + +* `Mark Skelton `_ diff --git a/LICENSE b/LICENSE index ba2effe..92fd315 100644 --- a/LICENSE +++ b/LICENSE @@ -1,4 +1,4 @@ -Copyright (c) 2015-2020 by Onni Software Ltd. and its contributors +Copyright (c) 2015-2022 by Onni Software Ltd. and its contributors All rights reserved. Redistribution and use in source and binary forms of the software as well @@ -13,7 +13,7 @@ that the following conditions are met: and/or other materials provided with the distribution. * Neither the name of 'pyexcel-xlsxr' nor the names of the contributors - may not be used to endorse or promote products derived from this software + may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE AND DOCUMENTATION IS PROVIDED BY THE COPYRIGHT HOLDERS AND diff --git a/README.rst b/README.rst index 522045b..1ce7bf7 100644 --- a/README.rst +++ b/README.rst @@ -8,9 +8,6 @@ pyexcel-xlsxr - Let you focus on data, instead of xlsx format .. image:: https://raw.githubusercontent.com/pyexcel/pyexcel-mobans/master/images/awesome-badge.svg :target: https://awesome-python.com/#specific-formats-processing -.. image:: https://github.com/pyexcel/pyexcel-xlsxr/workflows/run_tests/badge.svg - :target: http://github.com/pyexcel/pyexcel-xlsxr/actions - .. image:: https://codecov.io/gh/pyexcel/pyexcel-xlsxr/branch/master/graph/badge.svg :target: https://codecov.io/gh/pyexcel/pyexcel-xlsxr @@ -18,8 +15,7 @@ pyexcel-xlsxr - Let you focus on data, instead of xlsx format :target: https://pypi.org/project/pyexcel-xlsxr -.. image:: https://pepy.tech/badge/pyexcel-xlsxr/month - :target: https://pepy.tech/project/pyexcel-xlsxr + .. image:: https://img.shields.io/gitter/room/gitterHQ/gitter.svg @@ -316,7 +312,7 @@ Then install relevant development requirements: #. pip install -r tests/requirements.txt Once you have finished your changes, please provide test case(s), relevant documentation -and update CHANGELOG.rst. +and update changelog.yml .. note:: @@ -335,7 +331,7 @@ On Linux/Unix systems, please launch your tests like this:: $ make -On Windows systems, please issue this command:: +On Windows, please issue this command:: > test.bat @@ -347,7 +343,7 @@ Please run:: $ make format -so as to beautify your code otherwise travis-ci may fail your unit test. +so as to beautify your code otherwise your build may fail your unit test.