@promptbook/utils
Version:
Promptbook: Create persistent AI agents that turn your company's scattered knowledge into action
32 lines (31 loc) • 1.2 kB
TypeScript
import type { HarnessDefinition } from './HarnessDefinition';
import type { HarnessInstallationMethod } from './HarnessInstallationOrigin';
/**
* Options describing where the harness command was found.
*
* @private internal utility of `resolveHarnessInstallationMethodFromPaths`
*/
type HarnessInstallationPaths = {
/**
* Harness whose command was located.
*/
readonly definition: HarnessDefinition;
/**
* Resolved path of the harness command with every symbolic link followed.
*/
readonly commandPath: string;
/**
* Root directory of global npm installations or `null` when npm could not be asked for it.
*/
readonly npmGlobalPrefixPath: string | null;
};
/**
* Decides how a harness command was installed from the place where it really lives.
*
* Only a command which npm owns may be updated with `npm install -g`, every other command has to be
* updated where it is installed, otherwise the update silently adds a second copy of the harness.
*
* @private internal utility of `promptbookCli`
*/
export declare function resolveHarnessInstallationMethodFromPaths(paths: HarnessInstallationPaths): HarnessInstallationMethod;
export {};