-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
43 changed files
with
1,723 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
name: Test | ||
|
||
on: | ||
- push | ||
- pull_request | ||
|
||
jobs: | ||
test: | ||
runs-on: ubuntu-latest | ||
|
||
strategy: | ||
fail-fast: false | ||
matrix: | ||
python-version: | ||
- "3.8" | ||
- "3.9" | ||
- "3.10" | ||
- "3.11" | ||
- "3.12" | ||
django: | ||
- "3.0" | ||
- "4.0" | ||
- "5.0" | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: Update pip | ||
run: python -m pip install --upgrade pip | ||
|
||
- name: Install Django 3.0 | ||
if: matrix.django == 3.0 | ||
run: pip install "Django>=3.0,<3.1" | ||
- name: Install Django 4.0 | ||
if: matrix.django == 4.0 | ||
run: pip install "Django>=4.0,<4.1" | ||
- name: Install Django 5.0 | ||
if: matrix.django == 5.0 | ||
run: pip install "Django>=5.0,<5.1" | ||
|
||
- name: Install requirements | ||
run: pip install -r requirements-ci.txt | ||
|
||
- name: Install package | ||
run: pip install -e . | ||
|
||
- name: Run tests | ||
run: python manage.py test | ||
|
||
publish: | ||
name: Build and publish Python 🐍 distributions 📦 to PyPI | ||
needs: test | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Set up Python 3.8 | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: 3.8 | ||
|
||
- name: Install req packages | ||
run: python -m pip install -U setuptools wheel | ||
|
||
- name: Build a binary wheel and a source tarball | ||
run: python setup.py sdist bdist_wheel | ||
|
||
- name: Publish Package on PyPI | ||
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags') | ||
uses: pypa/gh-action-pypi-publish@master | ||
with: | ||
user: __token__ | ||
password: ${{ secrets.PYPI_API_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
*.pyc | ||
.idea/ | ||
.pycharm_helpers/ | ||
.ipython/ | ||
dist/ | ||
*.egg-info/ | ||
build/ | ||
*.sw* | ||
.coverage | ||
.bash_history | ||
docker-compose.override.yaml |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
## 1.0.0 (2024-05-13) | ||
|
||
* Initial release |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
FROM debian:bookworm-slim | ||
|
||
ENV PYTHONUNBUFFERED 1 | ||
ENV LC_ALL=C.UTF-8 | ||
ARG DEBIAN_FRONTEND=noninteractive | ||
|
||
USER root | ||
|
||
RUN apt-get -y update && apt-get -y --no-install-recommends install \ | ||
build-essential \ | ||
gcc \ | ||
python3-venv \ | ||
python3-dev \ | ||
libffi-dev \ | ||
libssl-dev \ | ||
gettext \ | ||
&& \ | ||
rm -rf /var/lib/apt/lists/* /usr/share/doc/* /usr/share/locale/* /usr/share/man/* && \ | ||
mkdir -p /app && \ | ||
(useradd -m app || true) | ||
|
||
WORKDIR /app | ||
|
||
USER app | ||
|
||
ADD requirements-test.txt /app/ | ||
|
||
ENV PATH /home/app/venv/bin:$PATH | ||
ENV PKG_PIP_VERSION=24.0 | ||
|
||
RUN python3 -m venv ~/venv && \ | ||
pip install pip==${PKG_PIP_VERSION} && \ | ||
pip install wheel && \ | ||
pip install -r requirements-test.txt | ||
|
||
ADD . /app/ | ||
|
||
ENV DJANGO_SETTINGS_MODULE dev.settings |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
MIT License | ||
|
||
Copyright (c) 2024 RegioHelden GmbH | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in all | ||
copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
include LICENSE | ||
include README.md | ||
include CHANGELOG.md |
Oops, something went wrong.