Skip to content

Commit

Permalink
Merge pull request #685 from niccokunzmann/check-dist
Browse files Browse the repository at this point in the history
Check distribution build
  • Loading branch information
niccokunzmann committed Jul 3, 2024
2 parents 2f5a0a5 + 39f9603 commit 419cb77
Show file tree
Hide file tree
Showing 4 changed files with 31 additions and 9 deletions.
26 changes: 23 additions & 3 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -71,11 +71,30 @@ jobs:
parallel-finished: true
format: cobertura

test-distribution:
name: Check built package
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.12"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install wheel twine setuptools
- name: Build distribution files
run: python setup.py bdist_wheel sdist
- name: Check distribution files
run: twine check dist/*

deploy-tag-to-pypi:
# only deploy on tags, see https://stackoverflow.com/a/58478262/1320237
if: startsWith(github.ref, 'refs/tags/v')
needs:
- run-tests
- test-distribution
runs-on: ubuntu-latest
# This environment stores the TWINE_USERNAME and TWINE_PASSWORD
# see https://docs.github.com/en/actions/deployment/targeting-different-environments/using-environments-for-deployment
Expand All @@ -92,11 +111,11 @@ jobs:
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.9"
python-version: "3.12"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install wheel twine
pip install wheel twine setuptools
- name: Check the tag
run: |
PACKAGE_VERSION=`python setup.py --version`
Expand Down Expand Up @@ -133,7 +152,8 @@ jobs:
# only deploy on tags, see https://stackoverflow.com/a/58478262/1320237
if: startsWith(github.ref, 'refs/tags/v')
needs:
- run-tests
- run-tests
- test-distribution
runs-on: ubuntu-latest
environment:
name: github-release
Expand Down
1 change: 1 addition & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ Minor changes:
- Remove 4.x badge
- Update list of ``tox`` environments
- Use Coveralls' GitHub Action
- Check distribution in CI

Breaking changes:

Expand Down
12 changes: 6 additions & 6 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ files.
.. _`BSD`: https://github.com/collective/icalendar/issues/2

Quick start guide
-----------------
=================

``icalendar`` enables you to **create**, **inspect** and **modify**
calendaring information with Python.
Expand All @@ -58,7 +58,7 @@ To **install** the package, run::


Inspect Files
~~~~~~~~~~~~~
-------------

You can open an ``.ics`` file and see all the events::

Expand All @@ -74,7 +74,7 @@ You can open an ``.ics`` file and see all the events::
International Women's Day

Modify Content
~~~~~~~~~~~~~~
--------------

Such a calendar can then be edited and saved again.

Expand All @@ -91,7 +91,7 @@ Such a calendar can then be edited and saved again.
Create Events, TODOs, Journals, Alarms, ...
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-------------------------------------------

``icalendar`` supports the creation and parsing of all kinds of objects
in the iCalendar (RFC 5545) standard.
Expand All @@ -114,7 +114,7 @@ Have a look at `more examples
<https://icalendar.readthedocs.io/en/latest/usage.html>`_.

Use timezones of your choice
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
----------------------------

With ``icalendar``, you can localize your events to take place in different
timezones.
Expand All @@ -141,7 +141,7 @@ with the same result:
END:VEVENT
Version 6 with zoneinfo
~~~~~~~~~~~~~~~~~~~~~~~
-----------------------

Version 6 of ``icalendar`` switches the timezone implementation to ``zoneinfo``.
This only affects you if you parse ``icalendar`` objects with ``from_ical()``.
Expand Down
1 change: 1 addition & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@
version=version,
description=shortdesc,
long_description=longdesc,
long_description_content_type="text/x-rst",
classifiers=[ # https://pypi.python.org/pypi?%3Aaction=list_classifiers
'Development Status :: 3 - Alpha',
'Intended Audience :: Developers',
Expand Down

0 comments on commit 419cb77

Please sign in to comment.