Compare commits

..

No commits in common. "1a5d552cfc9f7ae4d2ff9810865ebf86e98d74b5" and "f41f8e28e504d4976b5b5255f7bb3dcd191c33e2" have entirely different histories.

2 changed files with 23 additions and 20 deletions

View file

@ -3,14 +3,12 @@
This is a little TUI based on [Textual] for entering new Teilchen and for
searching for existing Teilchen. Data is kept in a sqlite database.
It is not yet usable. It has tests.
It is not yet usable.
## Running tests
```sh
uv run pytest tests.py
# or if you have just
just test
```
## Observing the app's console
@ -27,18 +25,15 @@ Since we use uv, the incantation is a bit different from the [official documenat
In one terminal:
```sh
```shell
uv run textual console
# or if you have just
just console
```
And in the other:
```sh
```shell
# run,textual,run! ;)
uv run textual run --dev src/teilchensammler_cli/__init__.py
# or if you have just
just run-console
```
## Developing

View file

@ -1,6 +1,3 @@
the_app := "teilchensammler_cli.main"
uv_export_options := "--frozen --format requirements.txt --quiet --no-install-project"
[private]
default:
@just --list
@ -18,15 +15,17 @@ build:
console:
uv run textual console
the_app := "teilchensammler_cli.main"
# run app with logs going to console
run-console:
run-dev:
uv run textual run --dev {{ the_app }}
# run the app
run:
uv run python -m {{ the_app }}
uv_export_options := "--frozen --format requirements.txt --quiet --no-install-project"
# export dependencies into requirements files
exports-deps:
uv export {{ uv_export_options }} --output-file requirements.txt
@ -37,7 +36,7 @@ update-deps:
uv lock --upgrade
uv sync
# Run tests, ARGS are passed-through to pytest
# Run tests, args are passed-through to pytest
test *ARGS:
uv run pytest tests.py {{ ARGS }}
@ -45,21 +44,30 @@ test *ARGS:
coverage:
uv run pytest tests.py --cov=src/ --cov-report term --cov-report xml --cov-report html --cov-config pyproject.toml
# run python and markdown
lint:
# lint python code
lint-python:
uv run ruff check .
# lint markdown documents
lint-markdown:
markdownlint-cli2 .
# run python and markdown
lint: lint-python lint-markdown
# remove artefacts from dist/
clean:
rm dist/*.whl dist/*.tar.gz
# consider xargs, or something that won't explode on many files
# pretend we are CI
ci: lint
prek run --all-files
# woodpecker-cli exec "whatever"
[private]
bump segment:
uv version --bump {{ segment }}
# create a new realese [CURRENTLY USELESS]
release:
@echo remember to git tag and update pyproject.toml
uv build
# upload to package registry
# send newsletter
# take over the world