Theia API Documentation v1.77.0
    Preparing search index...

    Runs the AGENTS.md migration on startup and exposes it as a command.

    The migration writes into the workspace root, a file the user will see in source control, so unlike the silent customAgents.yml migration it always reports what it did. Migration is re-attempted when the workspace becomes trusted; roots added later are covered by the command.

    Implements

    Index
    logger: ILogger
    messageService?: MessageService
    migrationService: AgentsMdMigrationService
    openerService: OpenerService
    overrideWarningDelay: number = 1000

    How long the prompt customizations have to be stable before overrides are reported. The workspace template locations are configured only after the initial scan of the global ones, and each rescan fires several events; reporting on the first of them would show a notification for a state that is about to change.

    overrideWarningEnabled: boolean = false

    Set once the application and the workspace trust are ready, the earliest a report makes sense.

    overrideWarningTimer: Timeout | undefined
    overrideWarningUpdates: Promise<void> = ...
    shownOverrideFingerprint: number | undefined
    startupMigration: Promise<void> | undefined

    In-flight run started by onStart or by the initial trust resolution.

    storageService: WorkspaceStorageService
    toDispose: DisposableCollection = ...
    workspaceService: WorkspaceService
    workspaceTrustService: WorkspaceTrustService
    • Parameters

      • reportEmptyResult: boolean

        whether to tell the user when there was nothing to migrate. Only the command does: on startup the common case is that nothing is pending, and saying so every time would be noise.

      Returns Promise<void>

    • onDidChangeWorkspaceTrust fires for the initial trust resolution as well as for later transitions, and that resolution lands after onStart has already started a run and parked it on the same deferred. Both triggers therefore fire on an ordinary trusted startup. The service keeps them from migrating twice; this keeps the second one from reporting the result again.

      Deliberately an in-flight promise rather than a latch: a workspace that starts untrusted has nothing to migrate, and the run that matters is the one after the user grants trust.

      Returns Promise<void>