athena.4.0 (after athena.3.1)

Changes:

Dev-server

start-dev-server.sh passes its arguments to the dev-server unchanged; it no longer adds --generators.

Local datastore: --instance, --migration-source, --user, --datastore

Instead of proxying a deployed application, the dev-server can run a datastore engine on your machine. Pass the instance data with --instance in place of the backend URL:

.alan/devenv/system-types/webclient/scripts/start-dev-server.sh \
  ./systems/client \
  --instance ./deployments/test/systems/server \
  --user alice \
  --port 4000
Flag Meaning
--instance <path> The data to start with: an instance.json, a migration package (.migration, migration.pkg, or a .link to one), or a deployment system directory (deployments/<name>/systems/<system>) holding either. Selects the local datastore mode.
--migration-source <instance.json> The source data for a migration. Without it the migration runs on an empty dataset, which only works for a migration that needs no source data.
--user <name> Every request is authenticated as this user. Without it the session is anonymous, which only works for an application that allows anonymous users.
--datastore <directory> A datastore runenv directory (with tools/engine) to use instead of the one that is looked up.

The client system is given as before: a system directory or a package file. The datastore runs the model of that package.

--local-engine <path>

--local-engine was a switch and now takes the path of the client engine to serve: a built engine directory or an engine.zip, such as the one in the project’s runenv:

start-dev-server.sh https://app.example.com/client ./systems/client \
  --local-engine .alan/runenv/system-types/webclient/tools/engine.zip

The argument after --local-engine is always read as that path. A command that still uses it as a switch in front of the URL or the system (--local-engine https://app.example.com/client ...) now takes the URL as the engine path and fails; add the path.

In the local datastore mode there is no deployed application to take the engine from, so a local engine is always served: the one given with --local-engine, else the engine of the project’s runenv (.alan/runenv/system-types/<webclient | auto-webclient>/tools/engine.zip).

--generator <directory> replaces --generators

The webclient system type no longer ships the auto-webclient generator, and the --generators flag and the ALAN_GENERATOR_PATH environment variable are gone. For an auto-webclient system the dev-server uses the generator of the project’s runenv (.alan/runenv/system-types/auto-webclient/tools), so the gui definition is generated by the version the project deploys. Run ./alan fetch runenv before starting the dev-server; without a generator an auto-webclient system cannot be served.

--generator <directory> selects another one. It takes an auto-webclient runenv directory (the one holding tools/engine), not the directory of generator packages that --generators took.

Before the upgrade

Nothing.

After the upgrade

From athena.3.1 the syntax is unchanged.