How to use the autorest.AutoRest.DetectConfigurationFile function in autorest

To help you get started, we’ve selected a few autorest examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github Azure / autorest / src / vscode-autorest / server / document-context.ts View on Github external
public async Activate(): Promise {
    // tell autorest that it's view needs to be re-created.
    this.Manager.verbose(`Invalidating Autorest view.`);
    this.autorest.Invalidate();

    // if there is a process() running, kill it. 
    this.cancel();

    // reaquire the config file.
    this.autorest.configFileUri = await AutoRest.DetectConfigurationFile(this, this.RootUri);

    // if autorest is about to restart the work, stop that
    // so we can push it out a bit more.
    if (this._readyToRun) {
      clearTimeout(this._readyToRun);
      this._readyToRun = null;
    }
    return await this.RunAutoRest();
  }

autorest

The AutoRest tool generates client libraries for accessing RESTful web services. Input to AutoRest is an OpenAPI spec that describes the REST API.

MIT
Latest version published 1 year ago

Package Health Score

81 / 100
Full package analysis