Skip to content

Commit 97e3e68

Browse files
committed
📚 update project meta data
1 parent e7b153a commit 97e3e68

File tree

9 files changed

+105
-56
lines changed

9 files changed

+105
-56
lines changed

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,5 @@ With your PR, here is a check list:
44
- [ ] Has all code lines tested?
55
- [ ] Has `make format` been run?
66
- [ ] Please update CHANGELOG.yml(not CHANGELOG.rst)
7-
- [ ] Passes all Travis CI builds
87
- [ ] Has fair amount of documentation if your change is complex
98
- [ ] Agree on NEW BSD License for your contribution

.github/workflows/lint.yml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
name: lint
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
lint:
7+
runs-on: ubuntu-latest
8+
name: lint code
9+
steps:
10+
- uses: actions/checkout@v2
11+
- name: Set up Python
12+
uses: actions/setup-python@v1
13+
with:
14+
python-version: 3.11
15+
- name: lint
16+
run: |
17+
pip --use-deprecated=legacy-resolver install flake8
18+
pip --use-deprecated=legacy-resolver install -r tests/requirements.txt
19+
flake8 --exclude=.moban.d,docs,setup.py --builtins=unicode,xrange,long .
20+
python setup.py checkdocs

.github/workflows/moban-update.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,22 +8,22 @@ jobs:
88
- uses: actions/checkout@v2
99
with:
1010
ref: ${{ github.head_ref }}
11+
token: ${{ secrets.PAT }}
1112
- name: Set up Python
1213
uses: actions/setup-python@v1
1314
with:
14-
python-version: '3.7'
15+
python-version: '3.11'
1516
- name: check changes
1617
run: |
17-
pip install moban gitfs2 pypifs moban-jinja2-github moban-ansible
18+
pip install markupsafe==2.0.1
19+
pip install ruamel.yaml moban gitfs2 pypifs moban-jinja2-github moban-ansible
1820
moban
1921
git status
2022
git diff --exit-code
2123
- name: Auto-commit
2224
if: failure()
23-
uses: docker://cdssnc/auto-commit-github-action
24-
env:
25-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
25+
uses: stefanzweifel/git-auto-commit-action@v4
2626
with:
27-
args: >-
27+
commit_message: >-
2828
This is an auto-commit, updating project meta data,
2929
such as changelog.rst, contributors.rst

.github/workflows/pythonpublish.yml

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,16 @@ on:
55
types: [created]
66

77
jobs:
8-
deploy:
8+
pypi-publish:
9+
name: upload release to PyPI
910
runs-on: ubuntu-latest
11+
# Specifying a GitHub environment is optional, but strongly encouraged
12+
environment: pypi
13+
permissions:
14+
# IMPORTANT: this permission is mandatory for trusted publishing
15+
id-token: write
1016
steps:
17+
# retrieve your distributions here
1118
- uses: actions/checkout@v1
1219
- name: Set up Python
1320
uses: actions/setup-python@v1
@@ -16,11 +23,9 @@ jobs:
1623
- name: Install dependencies
1724
run: |
1825
python -m pip install --upgrade pip
19-
pip install setuptools wheel twine
20-
- name: Build and publish
21-
env:
22-
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
23-
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
26+
pip install setuptools wheel
27+
- name: Build
2428
run: |
2529
python setup.py sdist bdist_wheel
26-
twine upload dist/*
30+
- name: Publish package distributions to PyPI
31+
uses: pypa/gh-action-pypi-publish@release/v1

.github/workflows/tests.yml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
name: Run unit tests on Windows, Ubuntu and Mac
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
7+
test:
8+
name: ${{ matrix.os }} / ${{ matrix.python_version }}
9+
runs-on: ${{ matrix.os }}-latest
10+
strategy:
11+
fail-fast: false
12+
matrix:
13+
os: [Ubuntu]
14+
python_version: ["3.9.16"]
15+
16+
steps:
17+
- uses: actions/checkout@v2
18+
- name: Set up Python
19+
uses: actions/setup-python@v5
20+
with:
21+
python-version: ${{ matrix.python_version }}
22+
architecture: x64
23+
24+
- name: install
25+
run: |
26+
pip --use-deprecated=legacy-resolver install -r requirements.txt
27+
pip --use-deprecated=legacy-resolver install -r tests/requirements.txt
28+
pip --use-deprecated=legacy-resolver install -r rnd_requirements.txt
29+
- name: test
30+
run: |
31+
pip freeze
32+
nosetests --verbosity=3 --with-coverage --cover-package pyexcel_libxlsxw --cover-package tests tests --with-doctest --doctest-extension=.rst README.rst docs/source pyexcel_libxlsxw
33+
- name: Upload coverage
34+
uses: codecov/codecov-action@v1
35+
with:
36+
name: ${{ matrix.os }} Python ${{ matrix.python-version }}

LICENSE

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
Copyright (c) 2015-2020 by Onni Software Ltd. and its contributors
1+
Copyright (c) 2015-2025 by Onni Software Ltd. and its contributors
22
All rights reserved.
33

44
Redistribution and use in source and binary forms of the software as well
@@ -13,7 +13,7 @@ that the following conditions are met:
1313
and/or other materials provided with the distribution.
1414

1515
* Neither the name of 'pyexcel-libxlsxw' nor the names of the contributors
16-
may not be used to endorse or promote products derived from this software
16+
may be used to endorse or promote products derived from this software
1717
without specific prior written permission.
1818

1919
THIS SOFTWARE AND DOCUMENTATION IS PROVIDED BY THE COPYRIGHT HOLDERS AND

README.rst

Lines changed: 22 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -5,21 +5,19 @@ pyexcel-libxlsxw - Let you focus on data, instead of xlsx format
55
.. image:: https://raw.githubusercontent.com/pyexcel/pyexcel.github.io/master/images/patreon.png
66
:target: https://www.patreon.com/chfw
77

8-
.. image:: https://cdn.rawgit.com/sindresorhus/awesome/d7305f38d29fed78fa85652e3a63e154dd8e8829/media/badge.svg
8+
.. image:: https://raw.githubusercontent.com/pyexcel/pyexcel-mobans/master/images/awesome-badge.svg
99
:target: https://awesome-python.com/#specific-formats-processing
1010

11-
.. image:: https://travis-ci.org/pyexcel/pyexcel-libxlsxw.svg?branch=master
12-
:target: http://travis-ci.org/pyexcel/pyexcel-libxlsxw
13-
1411
.. image:: https://codecov.io/gh/pyexcel/pyexcel-libxlsxw/branch/master/graph/badge.svg
1512
:target: https://codecov.io/gh/pyexcel/pyexcel-libxlsxw
1613

1714
.. image:: https://badge.fury.io/py/pyexcel-libxlsxw.svg
1815
:target: https://pypi.org/project/pyexcel-libxlsxw
1916

2017

18+
2119
.. image:: https://pepy.tech/badge/pyexcel-libxlsxw/month
22-
:target: https://pepy.tech/project/pyexcel-libxlsxw/month
20+
:target: https://pepy.tech/project/pyexcel-libxlsxw
2321

2422

2523
.. image:: https://img.shields.io/gitter/room/gitterHQ/gitter.svg
@@ -39,26 +37,20 @@ using libxlsxwriter. You are likely to use it with `pyexcel <https://github.com/
3937
Support the project
4038
================================================================================
4139

42-
If your company has embedded pyexcel and its components into a revenue generating
43-
product, please support me on github, `patreon <https://www.patreon.com/bePatron?u=5537627>`_
44-
or `bounty source <https://salt.bountysource.com/teams/chfw-pyexcel>`_ to maintain
45-
the project and develop it further.
46-
47-
If you are an individual, you are welcome to support me too and for however long
48-
you feel like. As my backer, you will receive
49-
`early access to pyexcel related contents <https://www.patreon.com/pyexcel/posts>`_.
50-
51-
And your issues will get prioritized if you would like to become my patreon as `pyexcel pro user`.
52-
53-
With your financial support, I will be able to invest
54-
a little bit more time in coding, documentation and writing interesting posts.
40+
If your company uses pyexcel and its components in a revenue-generating product,
41+
please consider supporting the project on GitHub or
42+
`Patreon <https://www.patreon.com/bePatron?u=5537627>`_. Your financial
43+
support will enable me to dedicate more time to coding, improving documentation,
44+
and creating engaging content.
5545

5646

5747
Known constraints
5848
==================
5949

6050
Fonts, colors and charts are not supported.
6151

52+
Nor to read password protected xls, xlsx and ods files.
53+
6254
Installation
6355
================================================================================
6456

@@ -89,15 +81,8 @@ As a standalone library
8981

9082
>>> import os
9183
>>> import sys
92-
>>> if sys.version_info[0] < 3:
93-
... from StringIO import StringIO
94-
... else:
95-
... from io import BytesIO as StringIO
96-
>>> PY2 = sys.version_info[0] == 2
97-
>>> if PY2 and sys.version_info[1] < 7:
98-
... from ordereddict import OrderedDict
99-
... else:
100-
... from collections import OrderedDict
84+
>>> from io import BytesIO
85+
>>> from collections import OrderedDict
10186

10287

10388
Write to an xlsx file
@@ -139,7 +124,7 @@ Here's the sample code to write a dictionary to an xlsx file:
139124
>>> data = OrderedDict()
140125
>>> data.update({"Sheet 1": [[1, 2, 3], [4, 5, 6]]})
141126
>>> data.update({"Sheet 2": [[7, 8, 9], [10, 11, 12]]})
142-
>>> io = StringIO()
127+
>>> io = BytesIO()
143128
>>> save_data(io, data)
144129
>>> # do something with the io
145130
>>> # In reality, you might give it to your http response
@@ -225,26 +210,29 @@ Then install relevant development requirements:
225210
#. pip install -r tests/requirements.txt
226211

227212
Once you have finished your changes, please provide test case(s), relevant documentation
228-
and update CHANGELOG.rst.
213+
and update changelog.yml
229214

230215
.. note::
231216

232217
As to rnd_requirements.txt, usually, it is created when a dependent
233-
library is not released. Once the dependecy is installed
218+
library is not released. Once the dependency is installed
234219
(will be released), the future
235220
version of the dependency in the requirements.txt will be valid.
236221

237222

238223
How to test your contribution
239-
------------------------------
224+
--------------------------------------------------------------------------------
240225

241-
Although `nose` and `doctest` are both used in code testing, it is adviable that unit tests are put in tests. `doctest` is incorporated only to make sure the code examples in documentation remain valid across different development releases.
226+
Although `nose` and `doctest` are both used in code testing, it is advisable
227+
that unit tests are put in tests. `doctest` is incorporated only to make sure
228+
the code examples in documentation remain valid across different development
229+
releases.
242230

243231
On Linux/Unix systems, please launch your tests like this::
244232

245233
$ make
246234

247-
On Windows systems, please issue this command::
235+
On Windows, please issue this command::
248236

249237
> test.bat
250238

@@ -256,7 +244,7 @@ Please run::
256244

257245
$ make format
258246

259-
so as to beautify your code otherwise travis-ci may fail your unit test.
247+
so as to beautify your code otherwise your build may fail your unit test.
260248

261249

262250

docs/source/conf.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,8 @@
2222
# -- Project information -----------------------------------------------------
2323

2424
project = 'pyexcel-libxlsxw'
25-
copyright = '2015-2020 Onni Software Ltd.'
26-
author = 'chfw'
25+
copyright = '2015-2025 Onni Software Ltd.'
26+
author = 'C.W.'
2727
# The short X.Y version
2828
version = '0.6.0'
2929
# The full version, including alpha/beta/rc tags
@@ -57,7 +57,7 @@
5757
# The theme to use for HTML and HTML Help pages. See the documentation for
5858
# a list of builtin themes.
5959
#
60-
html_theme = 'alabaster'
60+
html_theme = 'sphinx_rtd_theme'
6161

6262
# Add any paths that contain custom static files (such as style sheets) here,
6363
# relative to this directory. They are copied after the builtin static files,
@@ -68,7 +68,8 @@
6868
# -- Options for intersphinx extension ---------------------------------------
6969

7070
# Example configuration for intersphinx: refer to the Python standard library.
71-
intersphinx_mapping = {'https://docs.python.org/3/': None}
71+
intersphinx_mapping = {'python': ('https://docs.python.org/3',
72+
'python-inv.txt')}
7273
# TODO: html_theme not configurable upstream
7374
html_theme = 'default'
7475

setup.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
locale.setlocale(locale.LC_ALL, "en_US.UTF-8")
2929

3030
NAME = "pyexcel-libxlsxw"
31-
AUTHOR = "chfw"
31+
AUTHOR = "C.W."
3232
VERSION = "0.6.0"
3333
3434
LICENSE = "New BSD"
@@ -75,7 +75,7 @@
7575
PUBLISH_COMMAND = "{0} setup.py sdist bdist_wheel upload -r pypi".format(sys.executable)
7676
HERE = os.path.abspath(os.path.dirname(__file__))
7777

78-
GS_COMMAND = ("gs pyexcel-libxlsxw v0.6.0 " +
78+
GS_COMMAND = ("gease pyexcel-libxlsxw v0.6.0 " +
7979
"Find 0.6.0 in changelog for more details")
8080
NO_GS_MESSAGE = ("Automatic github release is disabled. " +
8181
"Please install gease to enable it.")

0 commit comments

Comments
 (0)