Skip to main content
Version: 2026.6

Command lines

Everything the SDK windows do to set up a project, update it and publish an environment can also run from a terminal, with no window open: on a build machine, in a script or in CI. There are three command lines, one for each job:

Command lineDoes whatWindow it mirrors
SetupCliinstalls and updates the SDK, configures the projectVirtuademy ▸ Setup project
UpdateRoutinesCliruns the update routines of a new SDK versionVirtuademy ▸ Update routines
EnvironmentsClibuilds, previews and deploys environmentsVirtuademy ▸ Addressables management

They share the same conventions:

Unity -batchmode -nographics -projectPath <project> -logFile -
-executeMethod <method> <options>
  • Close the project in the Unity Editor first. The command starts its own editor on it.
  • Do not add -quit. The method exits the editor by itself, with an exit code, when its work is done. Some of the work is asynchronous (downloads, uploads), and -quit would cut it short.
  • Options are strict. Every option starts with -vd and has to be spelled exactly as written here. A misspelt option, an option given twice or a stray value (-vdWorlds 12 13, where a list takes commas: -vdWorlds 12,13) stops the run with exit code 10, before anything is changed.
  • Read the log. With -logFile - the log goes to the terminal. Every run ends with one line, [SetupCli] REPORT {json}, [UpdateRoutinesCli] REPORT {json} or [EnvironmentsCli] REPORT {json}, with what was found and done, then EXIT <code>. Nothing secret goes into the log or the report: no token, no upload link, nothing from the tenant configuration file.
  • Exit code 0 is success. The codes of each command line are listed below.
  • Several of the commands change many files. Commit or back up the project first.

Setup​

Method: Virtuademy.SDK.Environments.Setup.Editor.SetupCli.Run

Unity -batchmode -nographics -projectPath <project> -logFile -
-executeMethod Virtuademy.SDK.Environments.Setup.Editor.SetupCli.Run
-vdSetupVersion 2026.6.0
OptionMeaning
-vdSetupVersion <version>the Virtuademy version to install or move to, as the setup window lists it (for example 2026.6.0)
-vdSetupSteps <steps>the steps to run, separated by commas, with no spaces. Without it, the default steps run
-vdSetupRegistry <url or file>reads the list of versions from another address or a local file, to try a change before it is published

The steps, in the order they run:

StepDoes whatDefault
configurethe Configure button: the project settingsyes
sdkInstall next to Virtuademy SDK Environments, at -vdSetupVersion. It refuses a project that already has another version (exit 15): use updateyes
updateUpdate packages to selected version: moves a project that has another version to -vdSetupVersion. What the new version does not list is removed, and HybridCLR follows the version. It cannot be combined with sdkno
resolvedownloads again the Virtuademy git packages whose tag or branch moved on the remote, and leaves the others alone. It changes nothing when no package moved or when a remote could not be reached (the network being down is a warning, not a failure). The setup package itself is not touchedyes
interpreterInstall interpreteryes
addressablesFix Addressables configurations, as in Addressable setup: it resets the Addressables groups. A project that is already configured is left as it isyes
vslibraryVirtuademy ▸ Update VS Library. It takes more than a minute and cannot tell that it has already run, so it only runs when you askno
checkchanges nothing and reports. Exit 0 when the project is set up, 3 when it is not (a package that moved on its remote or Addressables that are not configured count). It cannot be combined with other steps: a launch that lists check with another step stops with exit 10no

The default steps are configure,sdk,resolve,interpreter,addressables.

One launch does one round. Every package change ends in a resolve and a reload of the editor's scripts, which cuts short the method that is running. So a launch applies what it can, stops after the first change that needs the editor to start again and exits with 2. Launch again, with the same arguments, until the code is 0. A new project takes three launches, sometimes a fourth; a project that is already set up takes one and is left as it is. Updating a project to another version with update takes two launches. When the move crosses a version that has an update routine, the log names the routine, with its command line: run it next (see below). SetupCli does not run it.

Exit codeMeaning
0every requested step is done
1unexpected error: the log has the details
2the project changed: launch again
3check found something not set up
10bad arguments
11Git cannot be run by the editor
12an editor module is missing (Unity Hub installs it)
13the list of versions could not be read
14the Unity version does not match the one the Virtuademy version needs
15the project has another version installed: use update
16Virtuademy SDK Environments is not installed
17the interpreter installation failed
18Configure failed
19the Addressables configuration failed
20vslibrary failed

When the project is opened in the editor, the setup also updates the packages by itself: see SDK setup. That check does not run in batch mode, which is what the resolve step is for.

Update routines​

Method: Virtuademy.BreakingChangeSolvers.UpdateRoutinesCli.Run

Unity -batchmode -nographics -projectPath <project> -logFile -
-executeMethod Virtuademy.BreakingChangeSolvers.UpdateRoutinesCli.Run
-vdRoutine 2026.6
-vdRoutineDoes what
listlists the routines the project has, their menu names and whether each one finds something to change (a dry scan). Changes nothing
2026.6v2026.5 -> v2026.6: the old names in your files, the POI page markers, the assets that share a GUID with a package and the legacy folders, as described in Upgrade from 2026.5. It does what the window does with its defaults: every file the scan finds, every option ticked
2026.5v2026.4.x -> v2026.5.0: connects the Mobile output of the Platform: Switch nodes, where it is not connected

When a project needs both, run 2026.6 first: 2026.5 saves graphs, so it refuses to start (exit 15) while 2026.6 still has Visual Scripting data to migrate.

OptionMeaning
-vdDryRunscans and reports, and changes nothing
-vdExclude <paths>leaves files out, as unticking them in the window does: asset paths separated by commas, or a folder when the path ends with /. For 2026.6 it concerns the files of the first step, the rewrite of names
-vdSkip <steps>2026.6 only: turns steps off, like their options in the window. unpin, pages, guids and folders, separated by commas
-vdTimeoutMinutes <n>ends a run that waits for the editor for too long. 60 by default

One launch is one round. 2026.6 rewrites scripts and the package manifest, so Unity has to recompile before the changed files can be saved again. The launch that changes the project exits with 2; launch again with the same arguments. The next launch waits for the files to be saved, reports what it did and what is left, and finds nothing more to change. Running it again after that finds nothing. The report names the files changed for each step, the ones left for a manual check, and what remains.

The routines are an assembly of their own, so they also run in a project that does not compile, which is the state the update can leave it in.

Exit codeMeaning
0nothing left to do
1unexpected error: the log has the details
2the project changed and Unity has to recompile: launch again
3a dry run found something to change
10bad arguments
11the routine's code is not loaded (the SDK's editor code did not compile)
12the project's scripts do not compile, so the changed files cannot be saved again
13finished with problems: files that could not be changed, files left for a manual check, or work still left. The report names them
14timeout
15run 2026.6 first

Environments: build and deploy​

Method: Virtuademy.SDK.Environments.Editor.EnvironmentsCli.Run

Unity -batchmode -nographics -projectPath <project> -logFile -
-executeMethod Virtuademy.SDK.Environments.Editor.EnvironmentsCli.Run
-vdCommand <command> [options]

It builds and publishes what the Addressables management window does with buttons. The scenes it builds are the ones ticked Include in build in the window's list, with their Platforms: the ticks are in Assets/Virtuademy/Editor/Settings/AddressablesSceneList.asset, a versioned file you should commit, and a probe or test scene that stays ticked is built too (see Choose the scenes to build). The Addressables have to be configured first: fix them in the window, or with the addressables step of the setup (a project that is not configured exits with 12).

-vdCommandDoes what
statusthe session, whether the Addressables are configured, the scene list and the interpreter. No network
session [-vdRenew]the session fields, among them the tenant label. With -vdRenew it renews an expired session, or exits with 11
tenant-config -vdConfigFile <path> [-vdEnv <key>] [-vdConfigFolder <folder>] [-vdAllowTracked]imports the file downloaded from the Back Office, as in Connect the SDK to your tenant. It does not log in. -vdEnv picks the environment of the file (the first one by default) and -vdConfigFolder the folder, under Assets/, to copy it to. The file holds the app's secret: when git does not ignore where it would land, the command exits with 23 and writes nothing, unless -vdAllowTracked says you mean it
worldsthe worlds you can deploy to, and where each included scene is already published
build [-vdScenes a,b]what Build Addressables does, interpreted scripts included: it builds every platform each included scene needs and zips the result into ServerData. -vdScenes limits it to some of the included scenes, by scene name
preview (-vdWorlds <ids> | -vdTenant) [-vdExpectTenant <label>] [-vdScenes a,b]what a deploy there would add and update, scene by scene. Read-only
deploy (-vdWorlds <ids> | -vdTenant) -vdExpectTenant <label> [-vdBuild] [-vdDryRun] [-vdScenes a,b]what Deploy and Build & Deploy do, to the worlds with the given ids (separated by commas) or, with -vdTenant, to the tenant. Without -vdBuild it uploads the zips already in ServerData. -vdDryRun does everything except the uploads and the imports, and reports what it would send

All the commands also take -vdTimeoutMinutes <n> (60 by default).

The command line does not set an environment's thumbnail or Localization File: after a deploy, set them in the Back Office, in the environment's Edit panel (Environments).

The target of a deploy is always explicit. A deploy names its worlds or the tenant, never "all". A world id that you cannot deploy to stops the command before anything is built or sent. -vdExpectTenant is required to deploy: it is the tenant label the session shows (session prints it), compared without regard to case with the tenant you are logged in to. A missing or different label stops the command with 24, before anything is built or sent. Every command that calls the platform (worlds, preview, deploy) also checks that the platform address the project is set up for is on the same host as the one your tenant's configuration names, and exits with 25 when it is not, so that your login is never sent to another platform. The report of those three says which tenant, environment and addresses it is about.

Unity -batchmode -nographics -projectPath <project> -logFile -
-executeMethod Virtuademy.SDK.Environments.Editor.EnvironmentsCli.Run
-vdCommand deploy -vdWorlds 12,13 -vdExpectTenant Acme -vdBuild

The archives in ServerData are not tied to a world or a tenant. Nothing records which world or tenant a build was tested on. deploy without -vdBuild uploads the archives that are there to whatever worlds or tenant you name, so the ones you tested for one target also go to another. After any change to a scene or a script, run build again (or add -vdBuild), and pass -vdScenes so that only the scenes you mean are built and sent. An archive built against an older version of the scripts is refused by the platform: see Build and deploy.

Logging in. The command line never opens a login: you log in once, in the editor, from Virtuademy ▸ Addressables management or Available Tenants (see Connect the SDK to your tenant). The session and its renewal are stored on that computer, and the commands renew an expired session silently. When that is not possible they exit with 11: open the editor, log in again, and relaunch. build needs a session only when the project has interpreted scripts, because the platform checks them (the build is refused without one, as in the window, unless the scripts have not changed since they were last published); a project without interpreted scripts builds without logging in. At tenant level the interpreted scripts are not uploaded, and the command says so.

A login made in the window may not reach the command line. The command line reads the login stored on the computer, and a login made in the editor window was seen not to be there for it: session still reported the earlier, expired one. The stored login is also one for the whole computer, shared by every Unity project on it. So before a command-line deploy, run -vdCommand session (with -vdRenew if it has expired) and check the tenant label and the environment it reports. If they are not the ones you mean, deploy from the window instead.

A timeout never cuts a deploy in half. When the time passes during a deploy, the scene being uploaded and imported is finished and no further step starts. The command exits with 21 and a report that says, for each world and scene, what was uploaded, started and linked, and what was not. importsStarted in the report counts the imports the platform accepted; they finish on the platform afterwards, so it is not a count of environments that are already live.

Exit codeMeaning
0done
1unexpected error: the log has the details
10bad arguments
11login required
12the Addressables are not configured
13nothing to build: no scene is included, or -vdScenes names one that is not
14the build failed
15the interpreted scripts did not pass the checks
16a world id you cannot deploy to
17the deploy finished with problems: the report says how much went through
18your login cannot deploy at tenant level
19the configuration file was not imported
20the platform could not be read
21timeout
22deploy without -vdBuild found a scene with no zip in ServerData
23tenant-config: git does not ignore where the file would land
24tenant not confirmed: -vdExpectTenant missing or different
25the platform address does not match the tenant you are logged in to

A build leaves the project on the last platform it built, as the window does.