fix(tool): the checks fetch the packages first
All checks were successful
CI / check (push) Successful in 21m0s
CI / deploy (push) Has been skipped

After a merge or a switch of branch the workspace's resolution could
still be the one from before, and the pre-push hook's analysis failed on
packages it couldn't find (v0.13.0's push, and the stack's on 17 Oct).
The checks now fetch what the checked-out pubspecs and lock name before
anything else, with --enforce-lockfile, so a check never changes the
lock. About 3 s when nothing is missing.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Tizian 「ティツィアーン」 <raisondetredev@pm.me>
This commit is contained in:
Tizian 「ティツィアーン」 2026-10-17 20:18:15 +02:00
commit 971af90ba0
Signed by: raisondetredev
GPG key ID: 07F6FCF405488B64

View file

@ -27,6 +27,13 @@ if ! git diff --quiet HEAD; then
echo 'Note: the working tree has uncommitted changes; they are checked too.'
fi
# The packages the checked-out pubspecs and lock name, fetched first: after a merge or a
# switch of branch the workspace's resolution can still be the one from before, and the
# analysis then failed on packages it couldn't find (2026-10-13, 2026-10-17). The lock
# decides (--enforce-lockfile), so a check never changes it.
echo '▸ Packages'
flutter pub get --enforce-lockfile > /dev/null
# Our own Dart files. Generated code is left out: the client package as a whole, the
# server's generated sources and test tools, and the app's localizations (gen-l10n). (A
# loop instead of mapfile: macOS ships bash 3.)