aliasmate 1.6.2 → 2.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +61 -3
- package/README.md +84 -884
- package/dist/cli/completion.d.ts +5 -0
- package/dist/cli/completion.d.ts.map +1 -0
- package/dist/cli/completion.js +144 -0
- package/dist/cli/completion.js.map +1 -0
- package/dist/cli/manage.d.ts +19 -0
- package/dist/cli/manage.d.ts.map +1 -0
- package/dist/cli/manage.js +231 -0
- package/dist/cli/manage.js.map +1 -0
- package/dist/cli/run.d.ts +6 -0
- package/dist/cli/run.d.ts.map +1 -0
- package/dist/cli/run.js +48 -0
- package/dist/cli/run.js.map +1 -0
- package/dist/cli/save.d.ts +8 -0
- package/dist/cli/save.d.ts.map +1 -0
- package/dist/cli/save.js +90 -0
- package/dist/cli/save.js.map +1 -0
- package/dist/cli/transfer.d.ts +6 -0
- package/dist/cli/transfer.d.ts.map +1 -0
- package/dist/cli/transfer.js +99 -0
- package/dist/cli/transfer.js.map +1 -0
- package/dist/core/commands.d.ts +29 -0
- package/dist/core/commands.d.ts.map +1 -0
- package/dist/core/commands.js +232 -0
- package/dist/core/commands.js.map +1 -0
- package/dist/core/env.d.ts +9 -0
- package/dist/core/env.d.ts.map +1 -0
- package/dist/core/env.js +45 -0
- package/dist/core/env.js.map +1 -0
- package/dist/core/executor.d.ts +7 -0
- package/dist/core/executor.d.ts.map +1 -0
- package/dist/{utils → core}/executor.js +10 -46
- package/dist/core/executor.js.map +1 -0
- package/dist/core/history.d.ts +11 -0
- package/dist/core/history.d.ts.map +1 -0
- package/dist/core/history.js +117 -0
- package/dist/core/history.js.map +1 -0
- package/dist/core/recent.d.ts +14 -0
- package/dist/core/recent.d.ts.map +1 -0
- package/dist/core/recent.js +54 -0
- package/dist/core/recent.js.map +1 -0
- package/dist/core/runner.d.ts +13 -0
- package/dist/core/runner.d.ts.map +1 -0
- package/dist/core/runner.js +83 -0
- package/dist/core/runner.js.map +1 -0
- package/dist/core/store.d.ts +29 -0
- package/dist/core/store.d.ts.map +1 -0
- package/dist/core/store.js +131 -0
- package/dist/core/store.js.map +1 -0
- package/dist/core/transfer.d.ts +20 -0
- package/dist/core/transfer.d.ts.map +1 -0
- package/dist/core/transfer.js +110 -0
- package/dist/core/transfer.js.map +1 -0
- package/dist/core/types.d.ts +29 -0
- package/dist/core/types.d.ts.map +1 -0
- package/dist/core/types.js +3 -0
- package/dist/core/types.js.map +1 -0
- package/dist/core/validate.d.ts +6 -0
- package/dist/core/validate.d.ts.map +1 -0
- package/dist/core/validate.js +139 -0
- package/dist/core/validate.js.map +1 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +172 -0
- package/dist/index.js.map +1 -0
- package/dist/ui/format.d.ts +19 -0
- package/dist/ui/format.d.ts.map +1 -0
- package/dist/ui/format.js +155 -0
- package/dist/ui/format.js.map +1 -0
- package/dist/ui/interactive.d.ts +62 -0
- package/dist/ui/interactive.d.ts.map +1 -0
- package/dist/ui/interactive.js +657 -0
- package/dist/ui/interactive.js.map +1 -0
- package/dist/ui/onboarding.d.ts +3 -0
- package/dist/ui/onboarding.d.ts.map +1 -0
- package/dist/ui/onboarding.js +82 -0
- package/dist/ui/onboarding.js.map +1 -0
- package/dist/ui/prompts.d.ts +3 -0
- package/dist/ui/prompts.d.ts.map +1 -0
- package/dist/ui/prompts.js +50 -0
- package/dist/ui/prompts.js.map +1 -0
- package/dist/ui/table.d.ts +18 -0
- package/dist/ui/table.d.ts.map +1 -0
- package/dist/ui/table.js +54 -0
- package/dist/ui/table.js.map +1 -0
- package/dist/ui/theme.d.ts +30 -0
- package/dist/ui/theme.d.ts.map +1 -0
- package/dist/ui/theme.js +58 -0
- package/dist/ui/theme.js.map +1 -0
- package/package.json +10 -11
- package/dist/cli.d.ts +0 -3
- package/dist/cli.d.ts.map +0 -1
- package/dist/cli.js +0 -253
- package/dist/cli.js.map +0 -1
- package/dist/commands/alias.d.ts +0 -30
- package/dist/commands/alias.d.ts.map +0 -1
- package/dist/commands/alias.js +0 -213
- package/dist/commands/alias.js.map +0 -1
- package/dist/commands/changelog.d.ts +0 -9
- package/dist/commands/changelog.d.ts.map +0 -1
- package/dist/commands/changelog.js +0 -72
- package/dist/commands/changelog.js.map +0 -1
- package/dist/commands/completion.d.ts +0 -31
- package/dist/commands/completion.d.ts.map +0 -1
- package/dist/commands/completion.js +0 -522
- package/dist/commands/completion.js.map +0 -1
- package/dist/commands/delete.d.ts +0 -14
- package/dist/commands/delete.d.ts.map +0 -1
- package/dist/commands/delete.js +0 -54
- package/dist/commands/delete.js.map +0 -1
- package/dist/commands/edit.d.ts +0 -16
- package/dist/commands/edit.d.ts.map +0 -1
- package/dist/commands/edit.js +0 -231
- package/dist/commands/edit.js.map +0 -1
- package/dist/commands/export.d.ts +0 -23
- package/dist/commands/export.d.ts.map +0 -1
- package/dist/commands/export.js +0 -122
- package/dist/commands/export.js.map +0 -1
- package/dist/commands/import.d.ts +0 -23
- package/dist/commands/import.d.ts.map +0 -1
- package/dist/commands/import.js +0 -235
- package/dist/commands/import.js.map +0 -1
- package/dist/commands/list.d.ts +0 -25
- package/dist/commands/list.d.ts.map +0 -1
- package/dist/commands/list.js +0 -58
- package/dist/commands/list.js.map +0 -1
- package/dist/commands/prev.d.ts +0 -15
- package/dist/commands/prev.d.ts.map +0 -1
- package/dist/commands/prev.js +0 -138
- package/dist/commands/prev.js.map +0 -1
- package/dist/commands/recent.d.ts +0 -24
- package/dist/commands/recent.d.ts.map +0 -1
- package/dist/commands/recent.js +0 -132
- package/dist/commands/recent.js.map +0 -1
- package/dist/commands/run.d.ts +0 -22
- package/dist/commands/run.d.ts.map +0 -1
- package/dist/commands/run.js +0 -217
- package/dist/commands/run.js.map +0 -1
- package/dist/commands/save.d.ts +0 -17
- package/dist/commands/save.d.ts.map +0 -1
- package/dist/commands/save.js +0 -232
- package/dist/commands/save.js.map +0 -1
- package/dist/commands/search.d.ts +0 -19
- package/dist/commands/search.d.ts.map +0 -1
- package/dist/commands/search.js +0 -113
- package/dist/commands/search.js.map +0 -1
- package/dist/commands/validate.d.ts +0 -10
- package/dist/commands/validate.d.ts.map +0 -1
- package/dist/commands/validate.js +0 -162
- package/dist/commands/validate.js.map +0 -1
- package/dist/storage/index.d.ts +0 -117
- package/dist/storage/index.d.ts.map +0 -1
- package/dist/storage/index.js +0 -262
- package/dist/storage/index.js.map +0 -1
- package/dist/utils/changelog.d.ts +0 -41
- package/dist/utils/changelog.d.ts.map +0 -1
- package/dist/utils/changelog.js +0 -192
- package/dist/utils/changelog.js.map +0 -1
- package/dist/utils/constants.d.ts +0 -48
- package/dist/utils/constants.d.ts.map +0 -1
- package/dist/utils/constants.js +0 -51
- package/dist/utils/constants.js.map +0 -1
- package/dist/utils/env.d.ts +0 -64
- package/dist/utils/env.d.ts.map +0 -1
- package/dist/utils/env.js +0 -199
- package/dist/utils/env.js.map +0 -1
- package/dist/utils/errors.d.ts +0 -30
- package/dist/utils/errors.d.ts.map +0 -1
- package/dist/utils/errors.js +0 -62
- package/dist/utils/errors.js.map +0 -1
- package/dist/utils/executor.d.ts +0 -33
- package/dist/utils/executor.d.ts.map +0 -1
- package/dist/utils/executor.js.map +0 -1
- package/dist/utils/formatters.d.ts +0 -30
- package/dist/utils/formatters.d.ts.map +0 -1
- package/dist/utils/formatters.js +0 -188
- package/dist/utils/formatters.js.map +0 -1
- package/dist/utils/history.d.ts +0 -37
- package/dist/utils/history.d.ts.map +0 -1
- package/dist/utils/history.js +0 -179
- package/dist/utils/history.js.map +0 -1
- package/dist/utils/llm-generator.d.ts +0 -21
- package/dist/utils/llm-generator.d.ts.map +0 -1
- package/dist/utils/llm-generator.js +0 -915
- package/dist/utils/llm-generator.js.map +0 -1
- package/dist/utils/onboarding.d.ts +0 -10
- package/dist/utils/onboarding.d.ts.map +0 -1
- package/dist/utils/onboarding.js +0 -316
- package/dist/utils/onboarding.js.map +0 -1
- package/dist/utils/paths.d.ts +0 -44
- package/dist/utils/paths.d.ts.map +0 -1
- package/dist/utils/paths.js +0 -115
- package/dist/utils/paths.js.map +0 -1
- package/dist/utils/prompts.d.ts +0 -66
- package/dist/utils/prompts.d.ts.map +0 -1
- package/dist/utils/prompts.js +0 -51
- package/dist/utils/prompts.js.map +0 -1
- package/dist/utils/recent.d.ts +0 -55
- package/dist/utils/recent.d.ts.map +0 -1
- package/dist/utils/recent.js +0 -102
- package/dist/utils/recent.js.map +0 -1
- package/dist/utils/validator.d.ts +0 -56
- package/dist/utils/validator.d.ts.map +0 -1
- package/dist/utils/validator.js +0 -413
- package/dist/utils/validator.js.map +0 -1
- package/dist/utils/version-checker.d.ts +0 -29
- package/dist/utils/version-checker.d.ts.map +0 -1
- package/dist/utils/version-checker.js +0 -191
- package/dist/utils/version-checker.js.map +0 -1
- package/whats-new.json +0 -217
package/dist/utils/errors.js
DELETED
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.ExitCode = exports.AliasMateError = void 0;
|
|
7
|
-
exports.exitWithError = exitWithError;
|
|
8
|
-
exports.handleError = handleError;
|
|
9
|
-
exports.isInquirerTTYError = isInquirerTTYError;
|
|
10
|
-
const chalk_1 = __importDefault(require("chalk"));
|
|
11
|
-
/**
|
|
12
|
-
* Custom error class for AliasMate specific errors
|
|
13
|
-
*/
|
|
14
|
-
class AliasMateError extends Error {
|
|
15
|
-
constructor(message, code) {
|
|
16
|
-
super(message);
|
|
17
|
-
this.code = code;
|
|
18
|
-
this.name = 'AliasMateError';
|
|
19
|
-
}
|
|
20
|
-
}
|
|
21
|
-
exports.AliasMateError = AliasMateError;
|
|
22
|
-
/**
|
|
23
|
-
* Exit codes for the CLI
|
|
24
|
-
*/
|
|
25
|
-
var ExitCode;
|
|
26
|
-
(function (ExitCode) {
|
|
27
|
-
ExitCode[ExitCode["Success"] = 0] = "Success";
|
|
28
|
-
ExitCode[ExitCode["GeneralError"] = 1] = "GeneralError";
|
|
29
|
-
ExitCode[ExitCode["InvalidInput"] = 2] = "InvalidInput";
|
|
30
|
-
ExitCode[ExitCode["FileNotFound"] = 3] = "FileNotFound";
|
|
31
|
-
ExitCode[ExitCode["PermissionDenied"] = 4] = "PermissionDenied";
|
|
32
|
-
})(ExitCode || (exports.ExitCode = ExitCode = {}));
|
|
33
|
-
/**
|
|
34
|
-
* Display an error message and exit with the appropriate code
|
|
35
|
-
*/
|
|
36
|
-
function exitWithError(message, exitCode = ExitCode.GeneralError) {
|
|
37
|
-
console.error(chalk_1.default.red('Error:'), message);
|
|
38
|
-
process.exit(exitCode);
|
|
39
|
-
}
|
|
40
|
-
/**
|
|
41
|
-
* Handle errors consistently across commands
|
|
42
|
-
*/
|
|
43
|
-
function handleError(error, context) {
|
|
44
|
-
if (error instanceof AliasMateError) {
|
|
45
|
-
exitWithError(error.message);
|
|
46
|
-
}
|
|
47
|
-
if (error instanceof Error) {
|
|
48
|
-
const message = context ? `${context}: ${error.message}` : error.message;
|
|
49
|
-
exitWithError(message);
|
|
50
|
-
}
|
|
51
|
-
exitWithError('An unknown error occurred');
|
|
52
|
-
}
|
|
53
|
-
/**
|
|
54
|
-
* Check if error is an inquirer TTY error
|
|
55
|
-
*/
|
|
56
|
-
function isInquirerTTYError(error) {
|
|
57
|
-
return (typeof error === 'object' &&
|
|
58
|
-
error !== null &&
|
|
59
|
-
'isTtyError' in error &&
|
|
60
|
-
error.isTtyError === true);
|
|
61
|
-
}
|
|
62
|
-
//# sourceMappingURL=errors.js.map
|
package/dist/utils/errors.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"errors.js","sourceRoot":"","sources":["../../src/utils/errors.ts"],"names":[],"mappings":";;;;;;AA6BA,sCAGC;AAKD,kCAWC;AAKD,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B,KAAK,CAAC,UAAU,KAAK,IAAI,CAC1B,CAAC;AACJ,CAAC"}
|
package/dist/utils/executor.d.ts
DELETED
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Result of a command execution
|
|
3
|
-
*/
|
|
4
|
-
export interface ExecutionResult {
|
|
5
|
-
/** Whether the command executed successfully */
|
|
6
|
-
success: boolean;
|
|
7
|
-
/** Standard output (may be empty when using stdio: 'inherit') */
|
|
8
|
-
stdout: string;
|
|
9
|
-
/** Standard error or error message */
|
|
10
|
-
stderr: string;
|
|
11
|
-
/** Exit code of the command (if available) */
|
|
12
|
-
exitCode?: number;
|
|
13
|
-
}
|
|
14
|
-
/**
|
|
15
|
-
* Execute a command in a specific directory
|
|
16
|
-
* Uses execa with shell mode for cross-platform compatibility
|
|
17
|
-
*
|
|
18
|
-
* @param command - The shell command to execute
|
|
19
|
-
* @param cwd - The working directory to execute the command in
|
|
20
|
-
* @param env - Optional environment variables to use (defaults to process.env)
|
|
21
|
-
* @returns A promise that resolves with the execution result
|
|
22
|
-
* @throws {Error} If the directory doesn't exist
|
|
23
|
-
*
|
|
24
|
-
* @example
|
|
25
|
-
* ```ts
|
|
26
|
-
* const result = await executeCommand('npm install', '/path/to/project');
|
|
27
|
-
* if (result.success) {
|
|
28
|
-
* console.log('Installation successful');
|
|
29
|
-
* }
|
|
30
|
-
* ```
|
|
31
|
-
*/
|
|
32
|
-
export declare function executeCommand(command: string, cwd: string, env?: NodeJS.ProcessEnv): Promise<ExecutionResult>;
|
|
33
|
-
//# sourceMappingURL=executor.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"executor.d.ts","sourceRoot":"","sources":["../../src/utils/executor.ts"],"names":[],"mappings":"AAIA;;GAEG;AACH,MAAM,WAAW,eAAe;IAC9B,gDAAgD;IAChD,OAAO,EAAE,OAAO,CAAC;IACjB,iEAAiE;IACjE,MAAM,EAAE,MAAM,CAAC;IACf,sCAAsC;IACtC,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IAAA,eAAK,EAAC,OAAO,EAAE;YACnB,KAAK,EAAE,IAAI;YACX,GAAG,EAAE,WAAW;YAChB,KAAK,EAAE,SAAS;YAChB,GAAG;SACJ,CAAC,CAAC;QAEH,OAAO;YACL,OAAO,EAAE,IAAI;YACb,MAAM,EAAE,EAAE;YACV,MAAM,EAAE,EAAE;YACV,QAAQ,EAAE,CAAC;SACZ,CAAC;IACJ,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,MAAM,UAAU,GAAG,KAAyB,CAAC;QAC7C,OAAO;YACL,OAAO,EAAE,KAAK;YACd,MAAM,EAAE,UAAU,CAAC,MAAM,IAAI,EAAE;YAC/B,MAAM,EAAE,UAAU,CAAC,MAAM,IAAI,UAAU,CAAC,OAAO;YAC/C,QAAQ,EAAE,UAAU,CAAC,QAAQ;SAC9B,CAAC;IACJ,CAAC;AACH,CAAC"}
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import { CommandAlias } from '../storage';
|
|
2
|
-
/**
|
|
3
|
-
* Supported output formats
|
|
4
|
-
*/
|
|
5
|
-
export type OutputFormat = 'json' | 'yaml' | 'table' | 'compact';
|
|
6
|
-
/**
|
|
7
|
-
* Validate if a string is a valid output format
|
|
8
|
-
*/
|
|
9
|
-
export declare function isValidFormat(format: string): format is OutputFormat;
|
|
10
|
-
/**
|
|
11
|
-
* Format aliases as JSON
|
|
12
|
-
*/
|
|
13
|
-
export declare function formatAsJSON(aliases: Record<string, CommandAlias>, pretty?: boolean): string;
|
|
14
|
-
/**
|
|
15
|
-
* Format aliases as YAML
|
|
16
|
-
*/
|
|
17
|
-
export declare function formatAsYAML(aliases: Record<string, CommandAlias>): string;
|
|
18
|
-
/**
|
|
19
|
-
* Format aliases as a table (default human-readable format)
|
|
20
|
-
*/
|
|
21
|
-
export declare function formatAsTable(aliases: Record<string, CommandAlias>): string;
|
|
22
|
-
/**
|
|
23
|
-
* Format aliases in compact format (one line per command)
|
|
24
|
-
*/
|
|
25
|
-
export declare function formatAsCompact(aliases: Record<string, CommandAlias>): string;
|
|
26
|
-
/**
|
|
27
|
-
* Format aliases based on the specified format
|
|
28
|
-
*/
|
|
29
|
-
export declare function formatAliases(aliases: Record<string, CommandAlias>, format?: OutputFormat): string;
|
|
30
|
-
//# sourceMappingURL=formatters.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"formatters.d.ts","sourceRoot":"","sources":["../../src/utils/formatters.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAE1C;;GAEG;AACH,MAAM,MAAM,YAAY,GAAG,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,SAAS,CAAC;AAEjE;;GAEG;AACH,wBAAgB,aAAa,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,IAAI,YAAY,CAEpE;AAED;;GAEG;AACH,wBAAgB,YAAY,CAC1B,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,YAAY,CAAC,EACrC,MAAM,GAAE,OAAc,GACrB,MAAM,CAER;AAED;;GAEG;AACH,wBAAgB,YAAY,CAAC,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,YAAY,CAAC,GAAG,MAAM,CAgC1E;AAED;;GAEG;AACH,wBAAgB,aAAa,CAAC,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,YAAY,CAAC,GAAG,MAAM,CAkD3E;AAED;;GAEG;AACH,wBAAgB,eAAe,CAAC,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,YAAY,CAAC,GAAG,MAAM,CA0C7E;AAED;;GAEG;AACH,wBAAgB,aAAa,CAC3B,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,YAAY,CAAC,EACrC,MAAM,GAAE,YAAsB,GAC7B,MAAM,CAaR"}
|
package/dist/utils/formatters.js
DELETED
|
@@ -1,188 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
-
}) : function(o, v) {
|
|
16
|
-
o["default"] = v;
|
|
17
|
-
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
-
var ownKeys = function(o) {
|
|
20
|
-
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
-
var ar = [];
|
|
22
|
-
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
-
return ar;
|
|
24
|
-
};
|
|
25
|
-
return ownKeys(o);
|
|
26
|
-
};
|
|
27
|
-
return function (mod) {
|
|
28
|
-
if (mod && mod.__esModule) return mod;
|
|
29
|
-
var result = {};
|
|
30
|
-
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
-
__setModuleDefault(result, mod);
|
|
32
|
-
return result;
|
|
33
|
-
};
|
|
34
|
-
})();
|
|
35
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
36
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
37
|
-
};
|
|
38
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
-
exports.isValidFormat = isValidFormat;
|
|
40
|
-
exports.formatAsJSON = formatAsJSON;
|
|
41
|
-
exports.formatAsYAML = formatAsYAML;
|
|
42
|
-
exports.formatAsTable = formatAsTable;
|
|
43
|
-
exports.formatAsCompact = formatAsCompact;
|
|
44
|
-
exports.formatAliases = formatAliases;
|
|
45
|
-
const chalk_1 = __importDefault(require("chalk"));
|
|
46
|
-
const fs = __importStar(require("fs"));
|
|
47
|
-
/**
|
|
48
|
-
* Validate if a string is a valid output format
|
|
49
|
-
*/
|
|
50
|
-
function isValidFormat(format) {
|
|
51
|
-
return ['json', 'yaml', 'table', 'compact'].includes(format);
|
|
52
|
-
}
|
|
53
|
-
/**
|
|
54
|
-
* Format aliases as JSON
|
|
55
|
-
*/
|
|
56
|
-
function formatAsJSON(aliases, pretty = true) {
|
|
57
|
-
return JSON.stringify(aliases, null, pretty ? 2 : 0);
|
|
58
|
-
}
|
|
59
|
-
/**
|
|
60
|
-
* Format aliases as YAML
|
|
61
|
-
*/
|
|
62
|
-
function formatAsYAML(aliases) {
|
|
63
|
-
const yamlLines = [];
|
|
64
|
-
for (const [name, alias] of Object.entries(aliases)) {
|
|
65
|
-
yamlLines.push(`${name}:`);
|
|
66
|
-
yamlLines.push(` command: "${alias.command.replace(/"/g, '\\"')}"`);
|
|
67
|
-
yamlLines.push(` directory: "${alias.directory}"`);
|
|
68
|
-
if (alias.pathMode) {
|
|
69
|
-
yamlLines.push(` pathMode: ${alias.pathMode}`);
|
|
70
|
-
}
|
|
71
|
-
if (alias.env && Object.keys(alias.env).length > 0) {
|
|
72
|
-
yamlLines.push(` env:`);
|
|
73
|
-
for (const [key, value] of Object.entries(alias.env)) {
|
|
74
|
-
const stringValue = String(value);
|
|
75
|
-
yamlLines.push(` ${key}: "${stringValue.replace(/"/g, '\\"')}"`);
|
|
76
|
-
}
|
|
77
|
-
}
|
|
78
|
-
if (alias.createdAt) {
|
|
79
|
-
yamlLines.push(` createdAt: "${alias.createdAt}"`);
|
|
80
|
-
}
|
|
81
|
-
if (alias.updatedAt) {
|
|
82
|
-
yamlLines.push(` updatedAt: "${alias.updatedAt}"`);
|
|
83
|
-
}
|
|
84
|
-
yamlLines.push('');
|
|
85
|
-
}
|
|
86
|
-
return yamlLines.join('\n');
|
|
87
|
-
}
|
|
88
|
-
/**
|
|
89
|
-
* Format aliases as a table (default human-readable format)
|
|
90
|
-
*/
|
|
91
|
-
function formatAsTable(aliases) {
|
|
92
|
-
const names = Object.keys(aliases).sort();
|
|
93
|
-
if (names.length === 0) {
|
|
94
|
-
return chalk_1.default.yellow('No saved commands found.');
|
|
95
|
-
}
|
|
96
|
-
const lines = [];
|
|
97
|
-
lines.push(chalk_1.default.bold(`\nSaved commands (${names.length}):\n`));
|
|
98
|
-
for (const name of names) {
|
|
99
|
-
const alias = aliases[name];
|
|
100
|
-
// Check if directory still exists
|
|
101
|
-
const dirExists = fs.existsSync(alias.directory);
|
|
102
|
-
const dirIndicator = dirExists ? '' : chalk_1.default.red(' [DIR NOT FOUND]');
|
|
103
|
-
// Get path mode with backward compatibility
|
|
104
|
-
const pathMode = alias.pathMode || 'saved';
|
|
105
|
-
// Truncate long commands for display
|
|
106
|
-
const maxCommandLength = 100;
|
|
107
|
-
let displayCommand = alias.command;
|
|
108
|
-
if (displayCommand.length > maxCommandLength) {
|
|
109
|
-
const firstLine = displayCommand.split('\n')[0];
|
|
110
|
-
if (firstLine.length > maxCommandLength) {
|
|
111
|
-
displayCommand = firstLine.substring(0, maxCommandLength) + '...';
|
|
112
|
-
}
|
|
113
|
-
else {
|
|
114
|
-
displayCommand = firstLine + ' [...]';
|
|
115
|
-
}
|
|
116
|
-
}
|
|
117
|
-
lines.push(chalk_1.default.cyan(` ${name}${dirIndicator}`));
|
|
118
|
-
lines.push(chalk_1.default.gray(` Command: ${displayCommand}`));
|
|
119
|
-
lines.push(chalk_1.default.gray(` Directory: ${alias.directory}`));
|
|
120
|
-
lines.push(chalk_1.default.gray(` Path Mode: ${pathMode === 'saved' ? '📁 Saved' : '📍 Current'}`));
|
|
121
|
-
// Show env var count if any are saved
|
|
122
|
-
if (alias.env && Object.keys(alias.env).length > 0) {
|
|
123
|
-
lines.push(chalk_1.default.gray(` Environment Variables: ${Object.keys(alias.env).length} saved`));
|
|
124
|
-
}
|
|
125
|
-
if (alias.createdAt) {
|
|
126
|
-
lines.push(chalk_1.default.gray(` Created: ${new Date(alias.createdAt).toLocaleString()}`));
|
|
127
|
-
}
|
|
128
|
-
lines.push('');
|
|
129
|
-
}
|
|
130
|
-
return lines.join('\n');
|
|
131
|
-
}
|
|
132
|
-
/**
|
|
133
|
-
* Format aliases in compact format (one line per command)
|
|
134
|
-
*/
|
|
135
|
-
function formatAsCompact(aliases) {
|
|
136
|
-
const names = Object.keys(aliases).sort();
|
|
137
|
-
if (names.length === 0) {
|
|
138
|
-
return 'No saved commands found.';
|
|
139
|
-
}
|
|
140
|
-
const lines = [];
|
|
141
|
-
for (const name of names) {
|
|
142
|
-
const alias = aliases[name];
|
|
143
|
-
const pathMode = alias.pathMode || 'saved';
|
|
144
|
-
const envCount = alias.env ? Object.keys(alias.env).length : 0;
|
|
145
|
-
// Truncate command for compact display
|
|
146
|
-
let displayCommand = alias.command;
|
|
147
|
-
const maxLength = 50;
|
|
148
|
-
if (displayCommand.length > maxLength) {
|
|
149
|
-
const firstLine = displayCommand.split('\n')[0];
|
|
150
|
-
if (firstLine.length > maxLength) {
|
|
151
|
-
displayCommand = firstLine.substring(0, maxLength) + '...';
|
|
152
|
-
}
|
|
153
|
-
else {
|
|
154
|
-
displayCommand = firstLine + '...';
|
|
155
|
-
}
|
|
156
|
-
}
|
|
157
|
-
// Format: name | command | directory | mode | envs
|
|
158
|
-
const parts = [
|
|
159
|
-
name.padEnd(20),
|
|
160
|
-
displayCommand.padEnd(52),
|
|
161
|
-
alias.directory.padEnd(30),
|
|
162
|
-
pathMode.padEnd(7),
|
|
163
|
-
];
|
|
164
|
-
if (envCount > 0) {
|
|
165
|
-
parts.push(`${envCount} env var${envCount > 1 ? 's' : ''}`);
|
|
166
|
-
}
|
|
167
|
-
lines.push(parts.join(' | '));
|
|
168
|
-
}
|
|
169
|
-
return lines.join('\n');
|
|
170
|
-
}
|
|
171
|
-
/**
|
|
172
|
-
* Format aliases based on the specified format
|
|
173
|
-
*/
|
|
174
|
-
function formatAliases(aliases, format = 'table') {
|
|
175
|
-
switch (format) {
|
|
176
|
-
case 'json':
|
|
177
|
-
return formatAsJSON(aliases);
|
|
178
|
-
case 'yaml':
|
|
179
|
-
return formatAsYAML(aliases);
|
|
180
|
-
case 'table':
|
|
181
|
-
return formatAsTable(aliases);
|
|
182
|
-
case 'compact':
|
|
183
|
-
return formatAsCompact(aliases);
|
|
184
|
-
default:
|
|
185
|
-
throw new Error(`Unsupported format: ${format}`);
|
|
186
|
-
}
|
|
187
|
-
}
|
|
188
|
-
//# sourceMappingURL=formatters.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"formatters.js","sourceRoot":"","sources":["../../src/utils/formatters.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAYA,sCAEC;AAKD,oCAKC;AAKD,oCAgCC;AAKD,sCAkDC;AAKD,0CA0CC;AAKD,sCAgBC;AAxLD,kDAA0B;AAC1B,uCAAyB;AAQzB;;GAEG;AACH,SAAgB,aAAa,CAAC,MAAc;IAC1C,OAAO,CAAC,MAAM,EAAE,MAAM,EAAE,OAAO,EAAE,SAAS,CAAC,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC;AAC/D,CAAC;AAED;;GAEG;AACH,SAAgB,YAAY,CAC1B,OAAqC,EACrC,SAAkB,IAAI;IAEtB,OAAO,IAAI,CAAC,SAAS,CAAC,OAAO,EAAE,IAAI,EAAE,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AACvD,CAAC;AAED;;GAEG;AACH,SAAgB,YAAY,CAAC,OAAqC;IAChE,MAAM,SAAS,GAAa,EAAE,CAAC;IAE/B,KAAK,MAAM,CAAC,IAAI,EAAE,KAAK,CAAC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,GAAG,CAAC,EAAE,CAAC;YACjB,KAAK,CAAC,IAAI,CAAC,GAAG,QAAQ,WAAW,QAAQ,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC;QAC9D,CAAC;QAED,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC;IAChC,CAAC;IAED,OAAO,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AAC1B,CAAC;AAED;;GAEG;AACH,SAAgB,aAAa,CAC3B,OAAqC,EACrC,SAAuB,OAAO;IAE9B,QAAQ,MAAM,EAAE,CAAC;QACf,KAAK,MAAM;YACT,OAAO,YAAY,CAAC,OAAO,CAAC,CAAC;QAC/B,KAAK,MAAM;YACT,OAAO,YAAY,CAAC,OAAO,CAAC,CAAC;QAC/B,KAAK,OAAO;YACV,OAAO,aAAa,CAAC,OAAO,CAAC,CAAC;QAChC,KAAK,SAAS;YACZ,OAAO,eAAe,CAAC,OAAO,CAAC,CAAC;QAClC;YACE,MAAM,IAAI,KAAK,CAAC,uBAAuB,MAAM,EAAE,CAAC,CAAC;IACrD,CAAC;AACH,CAAC"}
|
package/dist/utils/history.d.ts
DELETED
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Get the last command from shell history
|
|
3
|
-
*
|
|
4
|
-
* IMPORTANT: This reads from the shell history file, which may not include
|
|
5
|
-
* the most recent commands until the shell writes them.
|
|
6
|
-
*
|
|
7
|
-
* For best results, configure your shell for immediate history writing:
|
|
8
|
-
* - zsh: Add "setopt INC_APPEND_HISTORY" or "setopt SHARE_HISTORY" to ~/.zshrc
|
|
9
|
-
* - bash: Add "PROMPT_COMMAND='history -a'" to ~/.bashrc
|
|
10
|
-
* - PowerShell (Windows): History is written immediately by default
|
|
11
|
-
*
|
|
12
|
-
* Alternative: Use environment variable ALIASMATE_LAST_CMD passed from parent shell
|
|
13
|
-
*
|
|
14
|
-
* @returns The last command from history, or null if unavailable
|
|
15
|
-
*
|
|
16
|
-
* @example
|
|
17
|
-
* ```ts
|
|
18
|
-
* const lastCmd = getLastCommand();
|
|
19
|
-
* if (lastCmd) {
|
|
20
|
-
* console.log(`Last command was: ${lastCmd}`);
|
|
21
|
-
* }
|
|
22
|
-
* ```
|
|
23
|
-
*/
|
|
24
|
-
export declare function getLastCommand(): string | null;
|
|
25
|
-
/**
|
|
26
|
-
* Get shell-specific configuration instructions for real-time history
|
|
27
|
-
*
|
|
28
|
-
* @returns Instructions formatted for the user's shell
|
|
29
|
-
*
|
|
30
|
-
* @example
|
|
31
|
-
* ```ts
|
|
32
|
-
* const instructions = getHistoryConfigInstructions();
|
|
33
|
-
* console.log(`Configure your shell:\n${instructions}`);
|
|
34
|
-
* ```
|
|
35
|
-
*/
|
|
36
|
-
export declare function getHistoryConfigInstructions(): string;
|
|
37
|
-
//# sourceMappingURL=history.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"history.d.ts","sourceRoot":"","sources":["../../src/utils/history.ts"],"names":[],"mappings":"AAIA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,wBAAgB,cAAc,IAAI,MAAM,GAAG,IAAI,CAoG9C;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,4BAA4B,IAAI,MAAM,CAsBrD"}
|
package/dist/utils/history.js
DELETED
|
@@ -1,179 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
-
}) : function(o, v) {
|
|
16
|
-
o["default"] = v;
|
|
17
|
-
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
-
var ownKeys = function(o) {
|
|
20
|
-
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
-
var ar = [];
|
|
22
|
-
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
-
return ar;
|
|
24
|
-
};
|
|
25
|
-
return ownKeys(o);
|
|
26
|
-
};
|
|
27
|
-
return function (mod) {
|
|
28
|
-
if (mod && mod.__esModule) return mod;
|
|
29
|
-
var result = {};
|
|
30
|
-
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
-
__setModuleDefault(result, mod);
|
|
32
|
-
return result;
|
|
33
|
-
};
|
|
34
|
-
})();
|
|
35
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
-
exports.getLastCommand = getLastCommand;
|
|
37
|
-
exports.getHistoryConfigInstructions = getHistoryConfigInstructions;
|
|
38
|
-
const fs = __importStar(require("fs"));
|
|
39
|
-
const path = __importStar(require("path"));
|
|
40
|
-
const os = __importStar(require("os"));
|
|
41
|
-
/**
|
|
42
|
-
* Get the last command from shell history
|
|
43
|
-
*
|
|
44
|
-
* IMPORTANT: This reads from the shell history file, which may not include
|
|
45
|
-
* the most recent commands until the shell writes them.
|
|
46
|
-
*
|
|
47
|
-
* For best results, configure your shell for immediate history writing:
|
|
48
|
-
* - zsh: Add "setopt INC_APPEND_HISTORY" or "setopt SHARE_HISTORY" to ~/.zshrc
|
|
49
|
-
* - bash: Add "PROMPT_COMMAND='history -a'" to ~/.bashrc
|
|
50
|
-
* - PowerShell (Windows): History is written immediately by default
|
|
51
|
-
*
|
|
52
|
-
* Alternative: Use environment variable ALIASMATE_LAST_CMD passed from parent shell
|
|
53
|
-
*
|
|
54
|
-
* @returns The last command from history, or null if unavailable
|
|
55
|
-
*
|
|
56
|
-
* @example
|
|
57
|
-
* ```ts
|
|
58
|
-
* const lastCmd = getLastCommand();
|
|
59
|
-
* if (lastCmd) {
|
|
60
|
-
* console.log(`Last command was: ${lastCmd}`);
|
|
61
|
-
* }
|
|
62
|
-
* ```
|
|
63
|
-
*/
|
|
64
|
-
function getLastCommand() {
|
|
65
|
-
try {
|
|
66
|
-
// Check if the command was passed via environment variable
|
|
67
|
-
// This allows shell integration: export ALIASMATE_LAST_CMD="$(!:0-1)"
|
|
68
|
-
if (process.env.ALIASMATE_LAST_CMD) {
|
|
69
|
-
const cmd = process.env.ALIASMATE_LAST_CMD.trim();
|
|
70
|
-
if (cmd && !cmd.startsWith('aliasmate')) {
|
|
71
|
-
return cmd;
|
|
72
|
-
}
|
|
73
|
-
}
|
|
74
|
-
const homeDir = os.homedir();
|
|
75
|
-
const platform = os.platform();
|
|
76
|
-
let historyFile = null;
|
|
77
|
-
// Determine history file based on platform and shell
|
|
78
|
-
if (platform === 'win32') {
|
|
79
|
-
// Windows PowerShell history
|
|
80
|
-
const psHistoryPath = path.join(homeDir, 'AppData', 'Roaming', 'Microsoft', 'Windows', 'PowerShell', 'PSReadLine', 'ConsoleHost_history.txt');
|
|
81
|
-
if (fs.existsSync(psHistoryPath)) {
|
|
82
|
-
historyFile = psHistoryPath;
|
|
83
|
-
}
|
|
84
|
-
}
|
|
85
|
-
else {
|
|
86
|
-
// Unix-like systems (Linux, macOS)
|
|
87
|
-
const shell = process.env.SHELL || '';
|
|
88
|
-
if (shell.includes('zsh')) {
|
|
89
|
-
historyFile = path.join(homeDir, '.zsh_history');
|
|
90
|
-
}
|
|
91
|
-
else if (shell.includes('bash')) {
|
|
92
|
-
historyFile = path.join(homeDir, '.bash_history');
|
|
93
|
-
}
|
|
94
|
-
else if (shell.includes('fish')) {
|
|
95
|
-
historyFile = path.join(homeDir, '.local', 'share', 'fish', 'fish_history');
|
|
96
|
-
}
|
|
97
|
-
else {
|
|
98
|
-
// Try common locations
|
|
99
|
-
const possibleFiles = [
|
|
100
|
-
path.join(homeDir, '.zsh_history'),
|
|
101
|
-
path.join(homeDir, '.bash_history'),
|
|
102
|
-
path.join(homeDir, '.sh_history'),
|
|
103
|
-
path.join(homeDir, '.history'),
|
|
104
|
-
];
|
|
105
|
-
for (const file of possibleFiles) {
|
|
106
|
-
if (fs.existsSync(file)) {
|
|
107
|
-
historyFile = file;
|
|
108
|
-
break;
|
|
109
|
-
}
|
|
110
|
-
}
|
|
111
|
-
}
|
|
112
|
-
}
|
|
113
|
-
if (!historyFile || !fs.existsSync(historyFile)) {
|
|
114
|
-
return null;
|
|
115
|
-
}
|
|
116
|
-
// Read the history file
|
|
117
|
-
const content = fs.readFileSync(historyFile, 'utf8');
|
|
118
|
-
const lines = content.trim().split('\n');
|
|
119
|
-
// Process lines from most recent to oldest
|
|
120
|
-
for (let i = lines.length - 1; i >= 0; i--) {
|
|
121
|
-
let line = lines[i].trim();
|
|
122
|
-
if (!line)
|
|
123
|
-
continue;
|
|
124
|
-
// Handle zsh extended history format: : timestamp:0;command
|
|
125
|
-
if (line.match(/^:\s*\d+:\d+;/)) {
|
|
126
|
-
line = line.split(';').slice(1).join(';').trim();
|
|
127
|
-
}
|
|
128
|
-
// Handle fish history format: - cmd: command
|
|
129
|
-
if (line.startsWith('- cmd:')) {
|
|
130
|
-
line = line.substring(6).trim();
|
|
131
|
-
}
|
|
132
|
-
// Skip aliasmate commands, exit commands, and empty lines
|
|
133
|
-
if (line &&
|
|
134
|
-
!line.startsWith('aliasmate') &&
|
|
135
|
-
!line.startsWith('am ') &&
|
|
136
|
-
line !== 'exit' &&
|
|
137
|
-
line !== 'quit') {
|
|
138
|
-
return line;
|
|
139
|
-
}
|
|
140
|
-
}
|
|
141
|
-
return null;
|
|
142
|
-
}
|
|
143
|
-
catch (error) {
|
|
144
|
-
// Silent fail - return null if we can't read history
|
|
145
|
-
return null;
|
|
146
|
-
}
|
|
147
|
-
}
|
|
148
|
-
/**
|
|
149
|
-
* Get shell-specific configuration instructions for real-time history
|
|
150
|
-
*
|
|
151
|
-
* @returns Instructions formatted for the user's shell
|
|
152
|
-
*
|
|
153
|
-
* @example
|
|
154
|
-
* ```ts
|
|
155
|
-
* const instructions = getHistoryConfigInstructions();
|
|
156
|
-
* console.log(`Configure your shell:\n${instructions}`);
|
|
157
|
-
* ```
|
|
158
|
-
*/
|
|
159
|
-
function getHistoryConfigInstructions() {
|
|
160
|
-
const platform = os.platform();
|
|
161
|
-
const shell = process.env.SHELL || '';
|
|
162
|
-
if (platform === 'win32') {
|
|
163
|
-
return ('PowerShell writes history immediately. If using Git Bash, add to ~/.bashrc:\n' +
|
|
164
|
-
' PROMPT_COMMAND="history -a"');
|
|
165
|
-
}
|
|
166
|
-
else if (shell.includes('zsh')) {
|
|
167
|
-
return 'Add to ~/.zshrc:\n' + ' setopt INC_APPEND_HISTORY\n' + 'Then run: source ~/.zshrc';
|
|
168
|
-
}
|
|
169
|
-
else if (shell.includes('bash')) {
|
|
170
|
-
return 'Add to ~/.bashrc:\n' + ' PROMPT_COMMAND="history -a"\n' + 'Then run: source ~/.bashrc';
|
|
171
|
-
}
|
|
172
|
-
else if (shell.includes('fish')) {
|
|
173
|
-
return 'Fish writes history immediately by default';
|
|
174
|
-
}
|
|
175
|
-
return ('Configure your shell to write history immediately.\n' +
|
|
176
|
-
'For bash: Add PROMPT_COMMAND="history -a" to ~/.bashrc\n' +
|
|
177
|
-
'For zsh: Add "setopt INC_APPEND_HISTORY" to ~/.zshrc');
|
|
178
|
-
}
|
|
179
|
-
//# sourceMappingURL=history.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"history.js","sourceRo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AAK,CAAC,EAAE,CAAC;QACjC,OAAO,oBAAoB,GAAG,+BAA+B,GAAG,2BAA2B,CAAC;IAC9F,CAAC;SAAM,IAAI,KAAK,CAAC,QAAQ,CAAC,MAAM,CAAC,EAAE,CAAC;QAClC,OAAO,qBAAqB,GAAG,iCAAiC,GAAG,4BAA4B,CAAC;IAClG,CAAC;SAAM,IAAI,KAAK,CAAC,QAAQ,CAAC,MAAM,CAAC,EAAE,CAAC;QAClC,OAAO,4CAA4C,CAAC;IACtD,CAAC;IAED,OAAO,CACL,sDAAsD;QACtD,0DAA0D;QAC1D,sDAAsD,CACvD,CAAC;AACJ,CAAC"}
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Generate LLM.txt content with all AliasMate features and documentation
|
|
3
|
-
*/
|
|
4
|
-
export declare function generateLLMContent(): string;
|
|
5
|
-
/**
|
|
6
|
-
* Create llm.txt file in the specified directory
|
|
7
|
-
* @param targetDir - The directory where llm.txt should be created
|
|
8
|
-
* @returns The full path to the created file
|
|
9
|
-
*/
|
|
10
|
-
export declare function createLLMFile(targetDir: string): string;
|
|
11
|
-
/**
|
|
12
|
-
* Get the default LLM command configuration
|
|
13
|
-
* This command will be auto-created during onboarding
|
|
14
|
-
*/
|
|
15
|
-
export declare function getDefaultLLMCommand(): {
|
|
16
|
-
name: string;
|
|
17
|
-
command: string;
|
|
18
|
-
directory: string;
|
|
19
|
-
pathMode: 'current';
|
|
20
|
-
};
|
|
21
|
-
//# sourceMappingURL=llm-generator.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"llm-generator.d.ts","sourceRoot":"","sources":["../../src/utils/llm-generator.ts"],"names":[],"mappings":"AAIA;;GAEG;AACH,wBAAgB,kBAAkB,IAAI,MAAM,CA80B3C;AAED;;;;GAIG;AACH,wBAAgB,aAAa,CAAC,SAAS,EAAE,MAAM,GAAG,MAAM,CAOvD;AAED;;;GAGG;AACH,wBAAgB,oBAAoB,IAAI;IACtC,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,QAAQ,EAAE,SAAS,CAAC;CACrB,CAOA"}
|