commit 9b3e8ef8f490c5af4730b5fc6a2e1a4d5a350f14 Author: Andrea Date: Fri Oct 24 08:24:46 2025 +0000 Initial commit diff --git a/.gitea/workflows/code-quality.yaml b/.gitea/workflows/code-quality.yaml new file mode 100644 index 0000000..a27f824 --- /dev/null +++ b/.gitea/workflows/code-quality.yaml @@ -0,0 +1,24 @@ +name: Code Quality +on: + push: + +jobs: + lint: + runs-on: ubuntu-latest + steps: + - name: Check out repository code + uses: actions/checkout@v5 + + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: '3.x' + + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install pylint + + - name: Run lint + run: | + pylint --errors-only $(git ls-files '*.py') diff --git a/.gitea/workflows/run-tests.yaml b/.gitea/workflows/run-tests.yaml new file mode 100644 index 0000000..d4f867c --- /dev/null +++ b/.gitea/workflows/run-tests.yaml @@ -0,0 +1,26 @@ +name: Run tests +on: + push: + +jobs: + test: + runs-on: ubuntu-latest + steps: + - name: Check out repository code + uses: actions/checkout@v5 + + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: '3.x' + + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install -r requirements.txt + + - name: Run tests + run: | + pip install pytest + pytest + diff --git a/.github/workflows/code-quality.yaml b/.github/workflows/code-quality.yaml new file mode 100644 index 0000000..a27f824 --- /dev/null +++ b/.github/workflows/code-quality.yaml @@ -0,0 +1,24 @@ +name: Code Quality +on: + push: + +jobs: + lint: + runs-on: ubuntu-latest + steps: + - name: Check out repository code + uses: actions/checkout@v5 + + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: '3.x' + + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install pylint + + - name: Run lint + run: | + pylint --errors-only $(git ls-files '*.py') diff --git a/.github/workflows/run-tests.yaml b/.github/workflows/run-tests.yaml new file mode 100644 index 0000000..d4f867c --- /dev/null +++ b/.github/workflows/run-tests.yaml @@ -0,0 +1,26 @@ +name: Run tests +on: + push: + +jobs: + test: + runs-on: ubuntu-latest + steps: + - name: Check out repository code + uses: actions/checkout@v5 + + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: '3.x' + + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install -r requirements.txt + + - name: Run tests + run: | + pip install pytest + pytest + diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..c9ecce5 --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +src/__pycache__ +tests/__pycache__ \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000..9e0e2bb --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,6 @@ +# Changelog + +All notable changes to this project will be documented in this file. + +The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), +and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). diff --git a/README.md b/README.md new file mode 100644 index 0000000..94fd668 --- /dev/null +++ b/README.md @@ -0,0 +1,12 @@ +# Python Project + +A little template for Python projects. + +## Testing + +This project uses [`pytest`](https://docs.pytest.org/en/stable/), once installed the tests can be runned with: + +```sh +pytest +``` + diff --git a/docs/.gitkeep b/docs/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/requirements.txt b/requirements.txt new file mode 100644 index 0000000..de43fe8 --- /dev/null +++ b/requirements.txt @@ -0,0 +1 @@ +# List of dependencies \ No newline at end of file diff --git a/src/__init__.py b/src/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/src/main.py b/src/main.py new file mode 100644 index 0000000..c633bc4 --- /dev/null +++ b/src/main.py @@ -0,0 +1,7 @@ +#! /usr/bin/env python + +def main(): + pass + +if __name__ == "__main__": + main() diff --git a/tests/__init__.py b/tests/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/tests/test_main.py b/tests/test_main.py new file mode 100644 index 0000000..da8b6c4 --- /dev/null +++ b/tests/test_main.py @@ -0,0 +1,10 @@ +from src.main import main +import unittest + +class TestMain(unittest.TestCase): + def test_main(self): + self.assertEqual(True, True) + + +if __name__ == '__main__': + unittest.main()