[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"

[project]
name = "edwh-auth-rbac"
dynamic = ["version"]
description = 'Recursive Memberships and Permissions for the Education Warehouse Authentication System'
readme = "README.md"
requires-python = ">=3.10"
license = "MIT"
keywords = ['edwh', 'omgeving', 'whitelabel']
authors = [
    { name = "Remco Boerma", email = "remco.b@educationwarehouse.nl" },
    { name = "Robin van der Noord", email = "robin.vdn@educationwarehouse.nl" },
]
classifiers = [
    "Development Status :: 4 - Beta",
    "Programming Language :: Python :: 3.10",
    "Programming Language :: Python :: 3.11",
    "Programming Language :: Python :: 3.12",
]
dependencies = [
    'dotmap',
    'edwh-migrate',
    'pydal',
]

[project.optional-dependencies]
dev = [
    "edwh",
    "edwh-migrate",
    "hatch",
    "python-semantic-release<8",
    "black",
    "su6[all]",
]

[project.urls]
Documentation = "https://github.com/educationwarehouse/edwh-auth-rbac#readme"
Issues = "https://github.com/educationwarehouse/edwh-auth-rbac/issues"
Source = "https://github.com/educationwarehouse/edwh-auth-rbac"


[tool.hatch.version]
path = "src/edwh_auth_rbac/__init__.py"

[tool.semantic_release]
branch = "master"
version_variable = "src/edwh_auth_rbac/__init__.py:__version__"
change_log = "CHANGELOG.md"
upload_to_repository = false
upload_to_release = false
build_command = "hatch build"

[tool.su6]
directory = "src"
include = []
exclude = []
# 'all':
stop-after-first-failure = false
# pytest:
coverage = 100
badge = true
# --format json indent
json-indent = 4

[tool.black]
target-version = ["py310"]
line-length = 120
# 'extend-exclude' excludes files or directories in addition to the defaults
extend-exclude = '''
# A regex preceded with ^/ will apply only to files and directories
# in the root of the project.
(
  ^.*\.bak\/.+     # ignore every .bak directory
  ^.*venv.+\/.+    # ignore every venv directory
  venv.+|.+\.bak   # idk why it suddenly works, let's not touch it
)
'''

[tool.hatch.build.targets.wheel]
packages = ["src/edwh_auth_rbac"]


[tool.isort]
profile = "black"
extend_skip_glob = ["venv*"]

[tool.pytest.ini_options]
pythonpath = [
    "src",
]