chore: scaffold the Serverpod 4 build

Deviations from a stock `serverpod create`:
- Dropped Flutter web support, for two reasons:
  - Appflowy editor had issues in the past, potentially related to the
    Flutter-Web IME bridge. Upstream has also open bugs in relation to
that:
    - AppFlowy-IO/appflowy-editor#1029 [Bug][Web] Unwanted space on click
       and overall space bugs (open)
    - AppFlowy-IO/appflowy-editor#782 [Bug] Editor auto-scrolling when
       pressing space too quickly if placed inside a scrollable (open)
  - Offline-first is a required feature. serverpod_offline_sync's SQLite
    support in browsers, maybe via sqlite3.wasm + OPFS, is not
documented.
- SDK constraints raised to ^3.13.0, instead of ^3.12.2, so enjoy the
  newest language features.
- Pinned to Flutter 3.47.4 via FVM.

Signed-off-by: Tizian 「ティツィアーン」 <raisondetredev@pm.me>
This commit is contained in:
Tizian 「ティツィアーン」 2026-09-16 19:24:59 +02:00
commit e17d99fa51
Signed by: raisondetredev
GPG key ID: 07F6FCF405488B64
3 changed files with 17563 additions and 0 deletions

43
.vscode/launch.json vendored Normal file
View file

@ -0,0 +1,43 @@
{
"version": "0.2.0",
"configurations": [
// If the server pubspec configures multiple Flutter apps, add an attach
// configuration like this for each app and add every configuration name
// to the compound below. Use the VM-service info file pattern
// `${workspaceFolder}/halkyon_learn_server/.dart_tool/serverpod/flutter-vm-service-info-<appId>.json`,
// where `<appId>` is the app's key under `serverpod.flutter_apps` in the
// server pubspec.
{
// Attaches to the Flutter app `serverpod start` spawns. Don't
// launch a second instance here - it would race for the port.
"name": "halkyon_learn_flutter",
"type": "dart",
"request": "attach",
"vmServiceInfoFile": "${workspaceFolder}/halkyon_learn_server/.dart_tool/serverpod/flutter-vm-service-info-halkyon_learn.json",
"preLaunchTask": "serverpod_start",
"internalConsoleOptions": "neverOpen"
},
{
"name": "halkyon_learn_server",
"type": "dart",
"request": "attach",
"vmServiceInfoFile": "${workspaceFolder}/halkyon_learn_server/.dart_tool/serverpod/vm-service-info.json",
"preLaunchTask": "serverpod_start",
"internalConsoleOptions": "neverOpen"
}
],
"compounds": [
{
"name": "halkyon_learn (full stack)",
"configurations": [
"halkyon_learn_server",
"halkyon_learn_flutter"
],
// Stopping one session stops both; the orphan blocks re-attach.
"stopAll": true,
"presentation": {
"order": 1
}
}
]
}

3
.vscode/settings.json vendored Normal file
View file

@ -0,0 +1,3 @@
{
"dart.flutterSdkPath": ".fvm/versions/3.47.4"
}

48
.vscode/tasks.json vendored Normal file
View file

@ -0,0 +1,48 @@
{
"version": "2.0.0",
"tasks": [
{
"label": "serverpod_start",
"type": "shell",
"command": "serverpod",
"args": ["start"],
"options": {
"cwd": "${workspaceFolder}/halkyon_learn_server",
"env": {
"SERVERPOD_PASSWORD_database": "zLZiS0hYW86MNDWF3fTB9iYudoEQ4rZG",
// Marks a `serverpod start` launched from the IDE, which is the
// only kind that honors the Flutter device picked in VS Code. A run
// started from a plain terminal carries no marker, so a device file
// left behind by a session that was killed cannot retarget it.
"SERVERPOD_LAUNCHED_FROM_IDE": "true"
}
},
"isBackground": true,
"presentation": {
"reveal": "always",
"panel": "dedicated"
},
// The TUI captures stdout, so we can't string-match for "ready". The
// attach config polls vm-service-info.json for the actual readiness
// signal; this matcher exists only to satisfy VS Code's requirement
// that background tasks declare one. The pattern intentionally never
// matches; begin/end patterns mark the task active+ready immediately.
"problemMatcher": {
"owner": "serverpod",
"pattern": [
{
"regexp": "^(SERVERPOD_NEVER_MATCH):(\\d+):(.+)$",
"file": 1,
"line": 2,
"message": 3
}
],
"background": {
"activeOnStart": true,
"beginsPattern": ".",
"endsPattern": "."
}
}
}
]
}