From e688bb63780ca3c3da9bd1dd4b494a47323df744 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Joakim=20Hells=C3=A9n?= Date: Thu, 16 Apr 2026 19:33:48 +0200 Subject: [PATCH] Add initial project files --- .python-version | 1 + .vscode/settings.json | 7 ++++ main.py | 6 ++++ pyproject.toml | 76 +++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 90 insertions(+) create mode 100644 .python-version create mode 100644 .vscode/settings.json create mode 100644 main.py create mode 100644 pyproject.toml diff --git a/.python-version b/.python-version new file mode 100644 index 0000000..6324d40 --- /dev/null +++ b/.python-version @@ -0,0 +1 @@ +3.14 diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 0000000..620582e --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,7 @@ +{ + "cSpell.words": [ + "Hellsén", + "Joakim", + "Tussilago" + ] +} \ No newline at end of file diff --git a/main.py b/main.py new file mode 100644 index 0000000..8200eef --- /dev/null +++ b/main.py @@ -0,0 +1,6 @@ +def main() -> None: + print("Hello from tussilago!") + + +if __name__ == "__main__": + main() diff --git a/pyproject.toml b/pyproject.toml new file mode 100644 index 0000000..732afc2 --- /dev/null +++ b/pyproject.toml @@ -0,0 +1,76 @@ +[project] +name = "tussilago" +version = "0.1.0" +description = "A platform to run and host Python applications." +readme = "README.md" +requires-python = ">=3.14" +dependencies = [] +license = "AGPL-3.0-or-later" +authors = [{ name = "Joakim Hellsén", email = "tlovinator@gmail.com" }] + +[tool.ruff] +fix = true +preview = true +unsafe-fixes = true + +format.docstring-code-format = true +format.preview = true + +lint.future-annotations = true +lint.isort.force-single-line = true +lint.pycodestyle.ignore-overlong-task-comments = true +lint.pydocstyle.convention = "google" +lint.select = ["ALL"] + +# Don't automatically remove unused variables +lint.unfixable = ["F841"] + +lint.ignore = [ + "ANN002", # Checks that function *args arguments have type annotations. + "ANN003", # Checks that function **kwargs arguments have type annotations. + "C901", # Checks for functions with a high McCabe complexity. + "CPY001", # Checks for the absence of copyright notices within Python files. + "D100", # Checks for undocumented public module definitions. + "D104", # Checks for undocumented public package definitions. + "D105", # Checks for undocumented magic method definitions. + "D106", # Checks for undocumented public class definitions, for nested classes. + "E501", # Checks for lines that exceed the specified maximum character length. + "ERA001", # Checks for commented-out Python code. + "FIX002", # Checks for "TODO" comments. + "PLR0911", # Checks for functions or methods with too many return statements. + "PLR0912", # Checks for functions or methods with too many branches, including (nested) if, elif, and else branches, for loops, try-except clauses, and match and case statements. + "PLR6301", # Checks for the presence of unused self parameter in methods definitions. + "RUF012", # Checks for mutable default values in class attributes. + "ARG001", # Checks for the presence of unused arguments in function definitions. + + # Conflicting lint rules when using Ruff's formatter + # https://docs.astral.sh/ruff/formatter/#conflicting-lint-rules + "COM812", # Checks for the absence of trailing commas. + "COM819", # Checks for the presence of prohibited trailing commas. + "D206", # Checks for docstrings that are indented with tabs. + "D300", # Checks for docstrings that use '''triple single quotes''' instead of """triple double quotes""". + "E111", # Checks for indentation with a non-multiple of 4 spaces. + "E114", # Checks for indentation of comments with a non-multiple of 4 spaces. + "E117", # Checks for over-indented code. + "ISC001", # Checks for implicitly concatenated strings on a single line. + "ISC002", # Checks for implicitly concatenated strings that span multiple lines. + "Q000", # Checks for inline strings that use single quotes or double quotes, depending on the value of the lint.flake8-quotes.inline-quotes option. + "Q001", # Checks for multiline strings that use single quotes or double quotes, depending on the value of the lint.flake8-quotes.multiline-quotes setting. + "Q002", # Checks for docstrings that use single quotes or double quotes, depending on the value of the lint.flake8-quotes.docstring-quotes setting. + "Q003", # Checks for strings that include escaped quotes, and suggests changing the quote style to avoid the need to escape them. + "W191", # Checks for indentation that uses tabs. +] + +[tool.ruff.lint.per-file-ignores] +"**/tests/**" = [ + "ARG", + "FBT", + "PLR0904", + "PLR2004", + "PLR6301", + "S101", + "S105", + "S106", + "S311", + "SLF001", +]