Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 6 additions & 8 deletions .github/workflows/python-publish-testpypi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,17 +13,15 @@ jobs:

steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- name: Set up Python
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
- name: Install uv
uses: astral-sh/setup-uv@08807647e7069bb48b6ef5acd8ec9567f424441b # v8.1.0
with:
python-version: '3.x'
- name: Install build dependencies
run: |
python -m pip install --upgrade pip
python -m pip install --upgrade build
# Install a specific version of uv.
version: "0.11.14"
enable-cache: true
- name: Build release distributions
run: |
python -m build
uv build
- name: Store the distribution packages
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
Expand Down
14 changes: 6 additions & 8 deletions .github/workflows/python-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,17 +10,15 @@ jobs:

steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- name: Set up Python
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
- name: Install uv
uses: astral-sh/setup-uv@08807647e7069bb48b6ef5acd8ec9567f424441b # v8.1.0
with:
python-version: '3.x'
- name: Install build dependencies
run: |
python -m pip install --upgrade pip
python -m pip install --upgrade build
# Install a specific version of uv.
version: "0.11.14"
enable-cache: true
- name: Build release distributions
run: |
python -m build
uv build
- name: Store the distribution packages
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
Expand Down
17 changes: 9 additions & 8 deletions .github/workflows/quality.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,20 +20,21 @@
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: ${{ matrix.python-version }}
cache: 'pip'
- name: Install uv
uses: astral-sh/setup-uv@08807647e7069bb48b6ef5acd8ec9567f424441b # v8.1.0
with:
# Install a specific version of uv.
version: "0.11.14"
enable-cache: true
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -r requirements.txt -r requirements-dev.txt
uv sync --all-extras --locked

Check warning on line 31 in .github/workflows/quality.yml

View check run for this annotation

SonarQubeCloud / SonarCloud Code Analysis

Omitting "--no-build" can lead to the execution of setup scripts. Make sure it is safe here.

See more on https://sonarcloud.io/project/issues?id=rafaelurben_python-mystrom&issues=AZ4thiHGp7ViVAVMVUMZ&open=AZ4thiHGp7ViVAVMVUMZ&pullRequest=151
- name: Check code formatting with black
run: |
python -m black --check .
- name: Install mypy types
run: |
python -m mypy --install-types --non-interactive .
uv run --locked python -m black --check .

Check warning on line 34 in .github/workflows/quality.yml

View check run for this annotation

SonarQubeCloud / SonarCloud Code Analysis

Omitting "--no-build" can lead to the execution of setup scripts. Make sure it is safe here.

See more on https://sonarcloud.io/project/issues?id=rafaelurben_python-mystrom&issues=AZ4thiHGp7ViVAVMVUMa&open=AZ4thiHGp7ViVAVMVUMa&pullRequest=151
- name: Check typing with mypy
run: |
python -m mypy --strict .
uv run --locked python -m mypy --strict .

Check warning on line 37 in .github/workflows/quality.yml

View check run for this annotation

SonarQubeCloud / SonarCloud Code Analysis

Omitting "--no-build" can lead to the execution of setup scripts. Make sure it is safe here.

See more on https://sonarcloud.io/project/issues?id=rafaelurben_python-mystrom&issues=AZ4thiHGp7ViVAVMVUMb&open=AZ4thiHGp7ViVAVMVUMb&pullRequest=151

codeql:
name: CodeQL Analysis
Expand Down
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright (c) 2025 Rafael Urben
Copyright (c) 2026 Rafael Urben

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
18 changes: 9 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -110,12 +110,12 @@ If you want to contribute to this project, feel free to open an issue or pull re

1. Fork the repository
2. Clone your forked repository
3. `python -m pip install -e .` to install the package in editable mode
4. Install dependencies and dev dependencies: `python -m pip install -r requirements.txt -r dev-requirements.txt`
5. Install mypy types: `python -m mypy --install-types --non-interactive .`
6. Make your changes
7. Format & check your code:
- Format your code with `python -m black .`
- Check typing with `python -m mypy --strict .`
8. Push your changes to your forked repository
9. Open a pull request
3. If you haven't already, install `uv`
from [here](https://docs.astral.sh/uv/getting-started/installation/).
4. Run `uv sync --locked --all-groups` to install the package and all dependencies.
5. Make your changes
6. Format & check your code:
- Format your code with `uv run --locked python -m black .`
- Check typing with `uv run --locked python -m mypy --strict .`
7. Push your changes to your forked repository
8. Open a pull request
12 changes: 10 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,7 @@ classifiers = [
]
requires-python = ">= 3.12"
dependencies = [
"requests>=2.25.1",
"packaging>=20.8",
"requests>=2.34.2",
]
dynamic = ["version"]

Expand All @@ -31,6 +30,15 @@ Homepage = "https://github.com/rafaelurben/python-mystrom"
GitHub = "https://github.com/rafaelurben/python-mystrom"
Issues = "https://github.com/rafaelurben/python-mystrom/issues"

[project.scripts]
pystrom = "pystrom.__main__:main"

[dependency-groups]
dev = [
"black==26.3.1",
"mypy==2.1.0",
]

[tool.setuptools]
include-package-data = true

Expand Down
7 changes: 6 additions & 1 deletion pystrom/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@

from pystrom.console import MyStromCommandParser

if __name__ == "__main__":

def main() -> None:
logging.basicConfig(level=logging.DEBUG, format="%(asctime)s - %(levelname)s - %(message)s")
MyStromCommandParser()


if __name__ == "__main__":
main()
2 changes: 0 additions & 2 deletions requirements-dev.txt

This file was deleted.

2 changes: 0 additions & 2 deletions requirements.txt

This file was deleted.

Loading