Skip to content

Commit

Permalink
feat: script to update dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
fyliu committed Mar 20, 2024
1 parent dd809ad commit 01f961f
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 0 deletions.
2 changes: 2 additions & 0 deletions docs/tools/scripts.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,3 +28,5 @@ These scripts assume you are using bash.
1. This assumes that `DJANGO_SUPERUSER_USERNAME` and `DJANGO_SUPERUSER_PASSWORD` are set in `.env.dev`

1. **erd.sh** - generate ER diagram

1. **update-dependencies.sh** - update python dependencies to the latest versions
6 changes: 6 additions & 0 deletions docs/tools/uv.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,12 @@ We shouldn't run this on every build, but we should do this manually every month
uv pip compile requirements.in -o requirements.txt --no-header --upgrade
```

Or run the script

```bash
./scripts/update-dependencies.sh
```

#### pip compile options

Disable header in the generated file
Expand Down
7 changes: 7 additions & 0 deletions scripts/update-dependencies.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#!/bin/bash
set -euo pipefail
IFS=$'\n\t'
set -x

# generate requirements.txt with the latest package versions
docker-compose exec web uv pip compile -o requirements.txt requirements.in --no-header --upgrade

0 comments on commit 01f961f

Please sign in to comment.