chore: update dependencies & scripts
This commit is contained in:
parent
2bf5607183
commit
738799cc74
15 changed files with 1351 additions and 993 deletions
10
scripts/install
Executable file
10
scripts/install
Executable file
|
|
@ -0,0 +1,10 @@
|
|||
#!/bin/sh -eu
|
||||
|
||||
cd "$RUN_DIR"
|
||||
|
||||
[ -z "${DEBUG:-}" ] || set -x
|
||||
|
||||
poetry install --with=dev --sync
|
||||
|
||||
cd unwind-ui
|
||||
npm ci
|
||||
|
|
@ -18,4 +18,4 @@ fi
|
|||
|
||||
cd unwind-ui
|
||||
npm run lint ||:
|
||||
npx prettier $prettier_opts 'vite.config.ts' 'src/**/*.{js,ts,vue}'
|
||||
npx --no -- prettier $prettier_opts 'vite.config.ts' 'src/**/*.{js,ts,vue}'
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ cd "$RUN_DIR"
|
|||
|
||||
[ -z "${DEBUG:-}" ] || set -x
|
||||
|
||||
ruff check --fix . ||:
|
||||
ruff format .
|
||||
poetry run ruff check --fix . ||:
|
||||
poetry run ruff format .
|
||||
|
||||
pyright
|
||||
poetry run pyright
|
||||
|
|
|
|||
13
scripts/outdated
Executable file
13
scripts/outdated
Executable file
|
|
@ -0,0 +1,13 @@
|
|||
#!/bin/sh -eu
|
||||
|
||||
cd "$RUN_DIR"
|
||||
|
||||
[ -z "${DEBUG:-}" ] || set -x
|
||||
|
||||
echo '# Poetry:'
|
||||
poetry show --outdated --top-level --with=build,dev
|
||||
|
||||
echo '
|
||||
# Npm:'
|
||||
cd unwind-ui
|
||||
npm outdated
|
||||
|
|
@ -10,6 +10,5 @@ trap 'rm "$dbfile" "${dbfile}-shm" "${dbfile}-wal"' EXIT TERM INT QUIT
|
|||
|
||||
[ -z "${DEBUG:-}" ] || set -x
|
||||
|
||||
export SQLALCHEMY_WARN_20=1 # XXX remove when we switched to SQLAlchemy 2.0
|
||||
UNWIND_STORAGE="$dbfile" \
|
||||
python -m pytest --cov "$@"
|
||||
exec poetry run pytest --cov "$@"
|
||||
|
|
|
|||
47
scripts/update
Executable file
47
scripts/update
Executable file
|
|
@ -0,0 +1,47 @@
|
|||
#!/bin/sh -eu
|
||||
|
||||
echo '
|
||||
WARNING:
|
||||
|
||||
This script aggressively updates all packages to the latest version.
|
||||
Be sure to run tests & check the application after this!
|
||||
|
||||
'
|
||||
|
||||
cd "$RUN_DIR"
|
||||
|
||||
[ -z "${DEBUG:-}" ] || set -x
|
||||
|
||||
|
||||
# Poetry
|
||||
|
||||
poetry update --with=build,dev
|
||||
|
||||
poetry show --outdated --top-level \
|
||||
| cut -d ' ' -f 1 \
|
||||
| while read -r pkg; do
|
||||
poetry add "$pkg@latest"
|
||||
done
|
||||
|
||||
poetry show --outdated --top-level --only=build \
|
||||
| cut -d ' ' -f 1 \
|
||||
| while read -r pkg; do
|
||||
poetry add --group=build "$pkg@latest"
|
||||
done
|
||||
|
||||
poetry show --outdated --top-level --only=dev \
|
||||
| cut -d ' ' -f 1 \
|
||||
| while read -r pkg; do
|
||||
poetry add --group=dev "$pkg@latest"
|
||||
done
|
||||
|
||||
|
||||
# Npm
|
||||
|
||||
cd unwind-ui
|
||||
npm update
|
||||
npm install $(npm outdated --json --silent | jq -r 'keys|map("\(.)@latest")|@sh')
|
||||
|
||||
npm outdated --json --silent \
|
||||
| jq -r 'keys|map(@sh"\(.)@latest")|join("\n")' \
|
||||
| xargs npm install
|
||||
Loading…
Add table
Add a link
Reference in a new issue