bl-log 0.2.10

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/dist/l-log ADDED
Binary file
@@ -0,0 +1,9 @@
1
+ #!/usr/bin/env bun
2
+ /**
3
+ * CLI tool for llm-lean-log
4
+ */
5
+ /**
6
+ * Main function for the CLI
7
+ */
8
+ export declare function main(): Promise<void>;
9
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";AACA;;GAEG;AA4FH;;GAEG;AACH,wBAAsB,IAAI,kBAuJzB"}
@@ -0,0 +1,6 @@
1
+ #!/usr/bin/env bun
2
+ /**
3
+ * CLI tool for llm-lean-log
4
+ */
5
+ export declare function main(version: string): Promise<void>;
6
+ //# sourceMappingURL=cli.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../../src/utils/cli.ts"],"names":[],"mappings":";AAEA;;GAEG;AAcH,wBAAsB,IAAI,CAAC,OAAO,EAAE,MAAM,iBAkLzC"}
@@ -0,0 +1,7 @@
1
+ export declare const VERSION = "0.2.9";
2
+ /**
3
+ * Help text for LLMs in CSV format
4
+ */
5
+ export declare const helpText = "l-log CLI - Usage: l-log <command> [log-file] [options]\n\ncommand,options,description\nlist|ls,\"--compact|-c,--human\",List all log entries\nstats,--human,Show log statistics\nview <index>,\"--last,--human\",View detailed entry at index\nsearch <query>,--human,Search logs by name/problem/solution\ntags <tag1> [tag2],--human,Filter logs by tags\nadd <name>,\"--tags=<tags>,--problem=<text>,--solution=<text>,--action=<text>,--files=<files>,--tech-stack=<tech>,--model=<name>,--cause=<text>,--causeIds=<ids>,--effectIds=<ids>,--created-at=<time>,--updated-at=<time>,--created-by-agent=<name>\",Add a new log entry\nhelp|-h|--help,--human,Show this help message\n-v|-V|--version,,Show version number\n\nexamples\nl-log list ./logs/example.csv\nl-log stats\nl-log view 0\nl-log view --last\nl-log search \"memory\"\nl-log tags error api\nl-log add ./logs/chat.csv \"Fix bug\" --tags=bug,fix --problem=\"Bug description\" --files=\"file1.ts,src/file2.ts\" --tech-stack=\"ts,react\" --cause=\"\" --causeIds=\"721ace2b-5e73-4901-bef9-97de16bf170f\" --model=\"gpt-4o\"\n";
6
+ export declare const helpTextForHuman = "l-log CLI\n\nUsage: l-log <command> [log-file] [options]\n\nCommands:\n list, ls List all log entries\n --compact, -c Show compact view\n --human Show human-readable output (with colors)\n \n stats Show log statistics\n --human Show human-readable output (with colors)\n \n view <index> View detailed entry at index\n --last Show the last log entry\n --human Show human-readable output (with colors)\n \n search <query> Search logs by name, problem, or solution\n --human Show human-readable output (with colors)\n \n tags <tag1> [tag2] Filter logs by tags\n --human Show human-readable output (with colors)\n \n add <name> Add a new log entry\n --tags=<tags> Comma-separated tags, wrap with double quotes if multiple tags\n --problem=<text> Problem description\n --solution=<text> Solution description\n --action=<text> Action taken\n --files=<files> Comma-separated files paths, wrap with double quotes if multiple files\n --tech-stack=<tech> Comma-separated tech stack, wrap with double quotes if multiple tech stack\n --model=<name> Model name\n --cause=<text> Cause description\n --causeIds=<ids> Comma-separated cause log row UUIDs, wrap with double quotes if multiple cause log row UUIDs\n --effectIds=<ids> Comma-separated effect log row UUIDs, wrap with double quotes if multiple effect log row UUIDs\n --last-commit-short-sha=<sha> Last git commit short SHA\n --created-at=<time> Creation time (ISO 8601 formatted string)\n --updated-at=<time> Update time (ISO 8601 formatted string)\n --created-by-agent=<name> Agent model name\n \n help, -h, --help Show this help message\n --human Show human-readable output (default for terminal)\n \n -v, -V, --version Show version number\n\nExamples for LLMs:\n l-log list ./logs/example.csv\n l-log stats\n l-log view 0\n l-log view --last\n l-log search \"memory\"\n l-log tags error api\n l-log add ./logs/chat.csv \"Fix bug\" --tags=bug,fix --problem=\"Bug description\" --files=\"file1.ts,src/file2.ts\" --tech-stack=\"ts,react\" --cause=\"\" --causeIds=\"721ace2b-5e73-4901-bef9-97de16bf170f\" --model=\"gpt-4o\"\n";
7
+ //# sourceMappingURL=const.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"const.d.ts","sourceRoot":"","sources":["../../src/utils/const.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,OAAO,UAAU,CAAC;AAE/B;;GAEG;AACH,eAAO,MAAM,QAAQ,+iCAoBpB,CAAC;AAEF,eAAO,MAAM,gBAAgB,mzEAmD5B,CAAC"}
@@ -0,0 +1,3 @@
1
+ export declare const getLogFolderPathFromLogFilePath: (logFile: string) => string;
2
+ export declare const mkdirIfNotExists: (path: string) => void;
3
+ //# sourceMappingURL=files.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"files.d.ts","sourceRoot":"","sources":["../../src/utils/files.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,+BAA+B,GAAI,SAAS,MAAM,KAAG,MAEjE,CAAC;AAEF,eAAO,MAAM,gBAAgB,GAAI,MAAM,MAAM,KAAG,IAW/C,CAAC"}
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Get the short SHA of the last git commit.
3
+ * Returns undefined if not in a git repository or if git command fails.
4
+ */
5
+ export declare function getLastCommitShortSha(): Promise<string | undefined>;
6
+ /**
7
+ * Generate git diff excluding lock files and save to specified file.
8
+ * When folder of path is not exist, auto create folder.
9
+ * @param outputPath - Path where the diff file will be saved
10
+ * @returns Promise resolving to boolean indicating success
11
+ */
12
+ export declare function saveGitDiffExcludeLockFiles(outputPath: string): Promise<boolean>;
13
+ //# sourceMappingURL=git.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"git.d.ts","sourceRoot":"","sources":["../../src/utils/git.ts"],"names":[],"mappings":"AAIA;;;GAGG;AACH,wBAAsB,qBAAqB,IAAI,OAAO,CAAC,MAAM,GAAG,SAAS,CAAC,CAgCzE;AAED;;;;;GAKG;AACH,wBAAsB,2BAA2B,CAChD,UAAU,EAAE,MAAM,GAChB,OAAO,CAAC,OAAO,CAAC,CA4DlB"}
@@ -0,0 +1,31 @@
1
+ /**
2
+ * Visualizer for llm-lean-log
3
+ * Displays logs in a human-readable format
4
+ */
5
+ import type { LogEntry } from "llm-lean-log-core";
6
+ interface VisualizerOptions {
7
+ /** Show full details or compact view */
8
+ compact?: boolean;
9
+ /** Maximum width for columns */
10
+ maxWidth?: number;
11
+ /** Color output */
12
+ colors?: boolean;
13
+ /** Enable syntax highlighting for code blocks */
14
+ highlight?: boolean;
15
+ /** Optimize for LLM consumption (compact, no colors, no fancy boxes) */
16
+ llm?: boolean;
17
+ }
18
+ /**
19
+ * Visualize log entries in a table format
20
+ */
21
+ export declare function visualizeTable(entries: LogEntry[], options?: VisualizerOptions): string;
22
+ /**
23
+ * Visualize a single log entry in detail
24
+ */
25
+ export declare function visualizeEntry(entry: LogEntry, options?: VisualizerOptions): string;
26
+ /**
27
+ * Visualize log statistics
28
+ */
29
+ export declare function visualizeStats(entries: LogEntry[], options?: VisualizerOptions): string;
30
+ export {};
31
+ //# sourceMappingURL=visualizer.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"visualizer.d.ts","sourceRoot":"","sources":["../../src/utils/visualizer.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAGH,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAGlD,UAAU,iBAAiB;IAC1B,wCAAwC;IACxC,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,gCAAgC;IAChC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,mBAAmB;IACnB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,iDAAiD;IACjD,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,wEAAwE;IACxE,GAAG,CAAC,EAAE,OAAO,CAAC;CACd;AAmID;;GAEG;AACH,wBAAgB,cAAc,CAC7B,OAAO,EAAE,QAAQ,EAAE,EACnB,OAAO,GAAE,iBAAsB,GAC7B,MAAM,CAgHR;AAED;;GAEG;AACH,wBAAgB,cAAc,CAC7B,KAAK,EAAE,QAAQ,EACf,OAAO,GAAE,iBAAsB,GAC7B,MAAM,CAmFR;AAED;;GAEG;AACH,wBAAgB,cAAc,CAC7B,OAAO,EAAE,QAAQ,EAAE,EACnB,OAAO,GAAE,iBAAsB,GAC7B,MAAM,CA8FR"}
package/package.json ADDED
@@ -0,0 +1,53 @@
1
+ {
2
+ "name": "bl-log",
3
+ "version": "0.2.10",
4
+ "description": "CLI tool for llm-lean-log and Bun only",
5
+ "scripts": {
6
+ "cli": "bun run src/index.ts",
7
+ "build": "bun build src/index.ts --compile --outfile dist/l-log --target bun",
8
+ "compile:mac": "bun build src/index.ts --compile --target bun-darwin-arm64 --outfile dist/l-log-mac",
9
+ "compile:win": "bun build src/index.ts --compile --target bun-windows-x64 --outfile dist/l-log-win.exe",
10
+ "compile:linux": "bun build src/index.ts --compile --target bun-linux-x64 --outfile dist/l-log-linux",
11
+ "prepublishOnly": "bun run build",
12
+ "type": "tsc --noEmit"
13
+ },
14
+ "repository": {
15
+ "type": "git",
16
+ "url": "git+https://github.com/loclv/llm-lean-log.git",
17
+ "directory": "packages/bun-cli"
18
+ },
19
+ "bugs": {
20
+ "url": "https://github.com/loclv/llm-lean-log/issues"
21
+ },
22
+ "homepage": "https://github.com/loclv/llm-lean-log/tree/main/packages/bun-cli#readme",
23
+ "main": "dist/l-log",
24
+ "module": "dist/l-log",
25
+ "type": "module",
26
+ "bin": {
27
+ "l-log": "dist/l-log"
28
+ },
29
+ "files": [
30
+ "dist",
31
+ "README.md",
32
+ "LICENSE"
33
+ ],
34
+ "publishConfig": {
35
+ "access": "public"
36
+ },
37
+ "dependencies": {
38
+ "cli-highlight": "^2.1.11"
39
+ },
40
+ "devDependencies": {
41
+ "@types/bun": "latest",
42
+ "llm-lean-log-core": "0.2.5",
43
+ "typescript": "^5.9.3"
44
+ },
45
+ "keywords": [
46
+ "llm",
47
+ "logging",
48
+ "cli",
49
+ "csv",
50
+ "token-optimization"
51
+ ],
52
+ "license": "MIT"
53
+ }