[build-system]
build-backend = "hatchling.build"
requires = [
  "hatchling>=1.18",
  "hatch-vcs>=0.4",
]

[project]
name = "kitsunekko-tools"
description = "A set of scripts for creating a local kitsunekko mirror."
readme = "README.md"
dynamic = ["version"]
authors = [
  { name = "Ren Tatsumoto", email = "tatsu@autistici.org" },
]
dependencies = [
  "httpx[socks]>=0.28",
  "fire>=0.6.0",
]
license = {file = "LICENSE"}
requires-python = ">=3.11"

[project.scripts]
ktools = "kitsunekko_tools.__main__:main"

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

[tool.hatch.version]
source = "vcs"
path = "kitsunekko_tools/__version__.py"

[tool.hatch.build.hooks.vcs]
version-file = "kitsunekko_tools/__version__.py"

[tool.black]
line-length = 120
target-version = ['py311']

[tool.isort]
profile = "black"

[tool.hatch.envs.dev]
dependencies = [
  "mypy>=1.0.0",
  "isort",
  "pytest",
  "black",
]
[tool.hatch.envs.dev.scripts]
# run as `hatch run dev:scriptname`
check = "mypy --install-types --non-interactive {args:kitsunekko_tools tests}"
format = "bash \"$(git rev-parse --show-toplevel)/format.sh\""
test = "pytest;"
