build: Melos, a Dart check and every path for the single repository
- Melos 8.9 as the root's dev dependency, with scripts across the
workspace (analyze, test:dart, test:flutter, generate, check) and its
filters (--diff, --include-dependents); cli_util overridden to 0.5.2
for it, since Learn's flutter_launcher_icons asks for 0.4 and uses only
its logger, unchanged in 0.5.
- tool/check.dart in place of tool/check.sh: packages, formatting of our
own files, analysis, the tools' tests, then every package's tests
through Melos (--changed-since=<commit> for only what changed and what
depends on it). tool/pre-push is the hook: the signature check, then
the checks. CI generates every server's code and runs the same check.
- The images build from the root with a workspace narrowed to what they
need (tool/workspace_only.sh); compose, the deploy's migration test,
the snap, the release script, the editor's launch files and Learn's
asset tools (run from apps/learn) follow the new layout.
- The project's source is named as project-halkyon/halkyon (source link,
snap, F-Droid listing, release uploads); the AGPL packages carry the
licence's own text.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Tizian 「ティツィアーン」 <raisondetredev@pm.me>
2026-10-19 20:39:09 +02:00
|
|
|
#!/bin/sh
|
|
|
|
|
# Narrows the workspace in ./pubspec.yaml to the members named, for an image that builds
|
fix(deploy): the images drop third_party/'s overrides instead of copying it
Two deploys failed building the images (4 Nov 2026): first the
dictionaries' image lacked third_party/ (pub refuses an override whose
path is missing, exit 66), then, with it copied, pub refused the
overrides themselves, as the three plugins depend on the Flutter SDK,
which the dart image doesn't have (exit 69); every image would have.
No image's package uses them, so tool/workspace_only.sh, which already
narrows the root pubspec for an image, drops the overrides naming
third_party/, and no Dockerfile copies it.
Each image's build stage replayed from this commit with a standalone
Dart 3.13.4, a fresh pub cache, dash and mawk: all four build, and the
commit deployed before fails as the deploy did.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Tizian 「ティツィアーン」 <raisondetredev@pm.me>
2026-11-04 13:07:49 +01:00
|
|
|
# only those (the Dockerfiles of the servers and Learn's curator): pub then resolves
|
|
|
|
|
# without the other members, whose folders the image doesn't hold. Fails if one named
|
|
|
|
|
# isn't a member, so a renamed package fails the build loudly.
|
|
|
|
|
#
|
|
|
|
|
# It also drops the dependency overrides of third_party/'s patched Flutter plugins: an
|
|
|
|
|
# image has Dart without Flutter, and pub refuses an override depending on the Flutter
|
|
|
|
|
# SDK, used or not (exit 69, the deploys of 4 Nov 2026). No image's package uses them.
|
build: Melos, a Dart check and every path for the single repository
- Melos 8.9 as the root's dev dependency, with scripts across the
workspace (analyze, test:dart, test:flutter, generate, check) and its
filters (--diff, --include-dependents); cli_util overridden to 0.5.2
for it, since Learn's flutter_launcher_icons asks for 0.4 and uses only
its logger, unchanged in 0.5.
- tool/check.dart in place of tool/check.sh: packages, formatting of our
own files, analysis, the tools' tests, then every package's tests
through Melos (--changed-since=<commit> for only what changed and what
depends on it). tool/pre-push is the hook: the signature check, then
the checks. CI generates every server's code and runs the same check.
- The images build from the root with a workspace narrowed to what they
need (tool/workspace_only.sh); compose, the deploy's migration test,
the snap, the release script, the editor's launch files and Learn's
asset tools (run from apps/learn) follow the new layout.
- The project's source is named as project-halkyon/halkyon (source link,
snap, F-Droid listing, release uploads); the AGPL packages carry the
licence's own text.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Tizian 「ティツィアーン」 <raisondetredev@pm.me>
2026-10-19 20:39:09 +02:00
|
|
|
#
|
|
|
|
|
# sh tool/workspace_only.sh apps/learn/halkyon_learn_server packages/halkyon_base_server
|
|
|
|
|
set -eu
|
|
|
|
|
awk -v keep="$*" '
|
|
|
|
|
BEGIN { n = split(keep, k, " "); for (i = 1; i <= n; i++) wanted[" - " k[i]] = 1 }
|
fix(deploy): the images drop third_party/'s overrides instead of copying it
Two deploys failed building the images (4 Nov 2026): first the
dictionaries' image lacked third_party/ (pub refuses an override whose
path is missing, exit 66), then, with it copied, pub refused the
overrides themselves, as the three plugins depend on the Flutter SDK,
which the dart image doesn't have (exit 69); every image would have.
No image's package uses them, so tool/workspace_only.sh, which already
narrows the root pubspec for an image, drops the overrides naming
third_party/, and no Dockerfile copies it.
Each image's build stage replayed from this commit with a standalone
Dart 3.13.4, a fresh pub cache, dash and mawk: all four build, and the
commit deployed before fails as the deploy did.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Tizian 「ティツィアーン」 <raisondetredev@pm.me>
2026-11-04 13:07:49 +01:00
|
|
|
# An override held back until its next line says whether its path is in third_party.
|
|
|
|
|
held != "" {
|
|
|
|
|
line = held; held = ""
|
|
|
|
|
if ($0 ~ /^ path: third_party\//) { next }
|
|
|
|
|
print line
|
|
|
|
|
}
|
|
|
|
|
/^[a-z_]+:/ { overrides = ($0 == "dependency_overrides:") }
|
|
|
|
|
overrides && /^ [a-z0-9_]+:$/ { held = $0; next }
|
build: Melos, a Dart check and every path for the single repository
- Melos 8.9 as the root's dev dependency, with scripts across the
workspace (analyze, test:dart, test:flutter, generate, check) and its
filters (--diff, --include-dependents); cli_util overridden to 0.5.2
for it, since Learn's flutter_launcher_icons asks for 0.4 and uses only
its logger, unchanged in 0.5.
- tool/check.dart in place of tool/check.sh: packages, formatting of our
own files, analysis, the tools' tests, then every package's tests
through Melos (--changed-since=<commit> for only what changed and what
depends on it). tool/pre-push is the hook: the signature check, then
the checks. CI generates every server's code and runs the same check.
- The images build from the root with a workspace narrowed to what they
need (tool/workspace_only.sh); compose, the deploy's migration test,
the snap, the release script, the editor's launch files and Learn's
asset tools (run from apps/learn) follow the new layout.
- The project's source is named as project-halkyon/halkyon (source link,
snap, F-Droid listing, release uploads); the AGPL packages carry the
licence's own text.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Tizian 「ティツィアーン」 <raisondetredev@pm.me>
2026-10-19 20:39:09 +02:00
|
|
|
/^workspace:/ { block = 1; print; next }
|
|
|
|
|
block && /^ - / { if ($0 in wanted) { print; found[$0] = 1 }; next }
|
|
|
|
|
{ block = 0; print }
|
|
|
|
|
END {
|
|
|
|
|
for (w in wanted) if (!(w in found)) { print "Not a workspace member:" substr(w, 4) > "/dev/stderr"; failed = 1 }
|
|
|
|
|
exit failed
|
|
|
|
|
}
|
|
|
|
|
' pubspec.yaml >pubspec.yaml.narrowed
|
|
|
|
|
mv pubspec.yaml.narrowed pubspec.yaml
|