Commit 1b40899b authored by Jakob Moser's avatar Jakob Moser
Browse files

Merge branch 'uv' into 'master'

Migrate to UV

See merge request moser/poolpay!35
parents 24add338 93e87840
Loading
Loading
Loading
Loading

.python-version

0 → 100644
+1 −0
Original line number Diff line number Diff line
3.12
+6 −13
Original line number Diff line number Diff line
@@ -239,12 +239,12 @@ Clone the repository and set everything up:

```bash
git clone https://gitlab.cl.uni-heidelberg.de/moser/poolpay.git
cd /coli/poolpay
python3 -m venv venv
source venv/bin/activate
sudo apt install python3-dev  # to compile evdev, which is a requirement
pip install -r requirements.txt
sudo chown poolpay:poolpay /coli/poolpay

sudo su poolpay
cd /coli/poolpay
curl -LsSf https://astral.sh/uv/install.sh | sh
```

As last step, deploy the systemd unit:
@@ -256,19 +256,12 @@ sudo systemctl enable poolpay

Reboot. The application should start automatically.

You now need to provide it with a password to create (or, at later starts, unlock) the vault:
You could now also launch tools, e.g., the card interfacing tool:

```bash
sudo su poolpay
cd /coli/poolpay
source venv/bin/activate
python3 -m poolpay.admin unlock
```

You could also, for example, run the card interfacing tool:

```bash
python3 -m poolpay.card id
uv run -m poolpay.card id
```

## License
+1 −1
Original line number Diff line number Diff line
@@ -2,7 +2,7 @@
Description=PoolPay

[Service]
ExecStart=/coli/poolpay/venv/bin/python3 -m poolpay
ExecStart=/home/poolpay/.local/bin/uv run -m poolpay
WorkingDirectory=/coli/poolpay
User=poolpay
Restart=always
+15 −1
Original line number Diff line number Diff line
[project]
requires-python = ">=3.11"
name = "PoolPay"
version = "1.0.0"
description = "Raspberry Pi-based terminal to pay for drinks in student common room using NFC card"
readme = "README.md"
requires-python = ">=3.12"
dependencies = [
    "babel~=2.17.0",
    "evdev~=1.9.2",
    "mfrc522~=0.0.7",
    "pi-rc522~=2.3.0",
    "pygame~=2.6.1",
    "rpi-lgpio~=0.6",
    "sqlalchemy~=2.0.38",
    "textual~=3.1.0",
]

[tool.ruff.lint]
select = [

requirements.txt

deleted100644 → 0
+0 −8
Original line number Diff line number Diff line
babel~=2.17.0
evdev~=1.9.2
mfrc522~=0.0.7
pi-rc522~=2.3.0
pygame~=2.6.1
rpi-lgpio~=0.6
SQLAlchemy~=2.0.38
textual~=3.1.0
Loading