Skip to content

Commit

Permalink
docs(compiler): explain compilerPath argument
Browse files Browse the repository at this point in the history
  • Loading branch information
davidyuk committed Jul 28, 2023
1 parent 3cf8c77 commit 413d872
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/Middleware.ts
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ export default class Middleware
/**
* @param url - Url for middleware API
* @param options - Options
* @param options.ignoreVersion - Don't check node version
* @param options.ignoreVersion - Don't ensure that the middleware is supported
* @param options.retryCount - Amount of extra requests to do in case of failure
* @param options.retryOverallDelay - Time in ms to wait between all retries
*/
Expand Down
2 changes: 1 addition & 1 deletion src/Node.ts
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ export default class Node extends (NodeTransformed as unknown as NodeTransformed
/**
* @param url - Url for node API
* @param options - Options
* @param options.ignoreVersion - Don't check node version
* @param options.ignoreVersion - Don't ensure that the node is supported
* @param options.retryCount - Amount of extra requests to do in case of failure
* @param options.retryOverallDelay - Time in ms to wait between all retries
*/
Expand Down
9 changes: 7 additions & 2 deletions src/contract/compiler/Cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,19 @@ const getPackagePath = (): string => {
};

/**
* A wrapper around aesophia_cli, available only in Node.js
* Assumes that `escript` is available in PATH.
* A wrapper around aesophia_cli, available only in Node.js.
* Requires Erlang installed, assumes that `escript` is available in PATH.
*/
export default class CompilerCli extends CompilerBase {
#path: string;

#ensureCompatibleVersion = Promise.resolve();

/**
* @param compilerPath - A path to aesophia_cli binary, by default uses the integrated one
* @param options - Options
* @param options.ignoreVersion - Don't ensure that the compiler is supported
*/
constructor(
compilerPath = resolve(getPackagePath(), './bin/aesophia_cli'),
{ ignoreVersion }: { ignoreVersion?: boolean } = {},
Expand Down

0 comments on commit 413d872

Please sign in to comment.