Compare commits
1 Commits
d91c0bc255
...
b8952f9667
Author | SHA1 | Date |
---|---|---|
Lukáš Kucharczyk | b8952f9667 |
20
Makefile
20
Makefile
|
@ -3,6 +3,7 @@ all: css migrate
|
||||||
initialize: npm css migrate sethookdir loadplatforms
|
initialize: npm css migrate sethookdir loadplatforms
|
||||||
|
|
||||||
HTMLFILES := $(shell find games/templates -type f)
|
HTMLFILES := $(shell find games/templates -type f)
|
||||||
|
PYTHON_VERSION = 3.12
|
||||||
|
|
||||||
npm:
|
npm:
|
||||||
npm install
|
npm install
|
||||||
|
@ -10,17 +11,26 @@ npm:
|
||||||
css: common/input.css
|
css: common/input.css
|
||||||
npx tailwindcss -i ./common/input.css -o ./games/static/base.css
|
npx tailwindcss -i ./common/input.css -o ./games/static/base.css
|
||||||
|
|
||||||
css-dev: css
|
|
||||||
npx tailwindcss -i ./common/input.css -o ./games/static/base.css --watch
|
|
||||||
|
|
||||||
makemigrations:
|
makemigrations:
|
||||||
poetry run python manage.py makemigrations
|
poetry run python manage.py makemigrations
|
||||||
|
|
||||||
migrate: makemigrations
|
migrate: makemigrations
|
||||||
poetry run python manage.py migrate
|
poetry run python manage.py migrate
|
||||||
|
|
||||||
dev: migrate
|
init:
|
||||||
poetry run python manage.py runserver
|
pyenv install -s $(PYTHON_VERSION)
|
||||||
|
pyenv local $(PYTHON_VERSION)
|
||||||
|
pip install poetry
|
||||||
|
poetry install
|
||||||
|
npm install
|
||||||
|
|
||||||
|
dev:
|
||||||
|
@npx concurrently \
|
||||||
|
--names "Django,Tailwind" \
|
||||||
|
--prefix-colors "blue,green" \
|
||||||
|
"poetry run python manage.py runserver" \
|
||||||
|
"npx tailwindcss -i ./common/input.css -o ./games/static/base.css --watch"
|
||||||
|
|
||||||
|
|
||||||
caddy:
|
caddy:
|
||||||
caddy run --watch
|
caddy run --watch
|
||||||
|
|
14
README.md
14
README.md
|
@ -1,3 +1,15 @@
|
||||||
# Timetracker
|
# Timetracker
|
||||||
|
|
||||||
A simple game catalogue and play session tracker.
|
A simple game catalogue and play session tracker.
|
||||||
|
|
||||||
|
# Development
|
||||||
|
|
||||||
|
The project uses `pyenv` to manage installed Python versions.
|
||||||
|
If you have `pyenv` installed, you can simply run:
|
||||||
|
|
||||||
|
```
|
||||||
|
make init
|
||||||
|
```
|
||||||
|
|
||||||
|
This will make sure the correct Python version is installed, and it will install all dependencies using `poetry`.
|
||||||
|
Afterwards, you can start the development server using `make dev`.
|
|
@ -2,6 +2,7 @@
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@tailwindcss/forms": "^0.5.6",
|
"@tailwindcss/forms": "^0.5.6",
|
||||||
"@tailwindcss/typography": "^0.5.10",
|
"@tailwindcss/typography": "^0.5.10",
|
||||||
|
"concurrently": "^8.2.2",
|
||||||
"tailwindcss": "^3.3.3"
|
"tailwindcss": "^3.3.3"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue