src/vs/platform/terminal/common/xterm/shellIntegrationAddon.ts/ShellIntegrationAddon/serialize
class ShellIntegrationAddon:	serialize(): ISerializedCommandDetectionCapability {
		if (!this._terminal || !this.capabilities.has(TerminalCapability.CommandDetection)) {
			return {
				isWindowsPty: false,
				commands: []
			};
		}
		const result = this._createOrGetCommandDetection(this._terminal).serialize();
		return result;
	}