@towles/tool 0.0.20 → 0.0.41
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/LICENSE +21 -0
- package/LICENSE.md +9 -10
- package/README.md +121 -78
- package/bin/run.ts +5 -0
- package/package.json +63 -53
- package/patches/prompts.patch +34 -0
- package/src/commands/base.ts +42 -0
- package/src/commands/config.test.ts +15 -0
- package/src/commands/config.ts +43 -0
- package/src/commands/doctor.ts +133 -0
- package/src/commands/gh/branch-clean.ts +110 -0
- package/src/commands/gh/branch.test.ts +124 -0
- package/src/commands/gh/branch.ts +132 -0
- package/src/commands/gh/pr.ts +168 -0
- package/src/commands/index.ts +55 -0
- package/src/commands/install.ts +148 -0
- package/src/commands/journal/daily-notes.ts +66 -0
- package/src/commands/journal/meeting.ts +83 -0
- package/src/commands/journal/note.ts +83 -0
- package/src/commands/journal/utils.ts +399 -0
- package/src/commands/observe/graph.test.ts +89 -0
- package/src/commands/observe/graph.ts +1640 -0
- package/src/commands/observe/report.ts +166 -0
- package/src/commands/observe/session.ts +385 -0
- package/src/commands/observe/setup.ts +180 -0
- package/src/commands/observe/status.ts +146 -0
- package/src/commands/ralph/lib/execution.ts +302 -0
- package/src/commands/ralph/lib/formatter.ts +298 -0
- package/src/commands/ralph/lib/index.ts +4 -0
- package/src/commands/ralph/lib/marker.ts +108 -0
- package/src/commands/ralph/lib/state.ts +191 -0
- package/src/commands/ralph/marker/create.ts +23 -0
- package/src/commands/ralph/plan.ts +73 -0
- package/src/commands/ralph/progress.ts +44 -0
- package/src/commands/ralph/ralph.test.ts +673 -0
- package/src/commands/ralph/run.ts +408 -0
- package/src/commands/ralph/task/add.ts +105 -0
- package/src/commands/ralph/task/done.ts +73 -0
- package/src/commands/ralph/task/list.test.ts +48 -0
- package/src/commands/ralph/task/list.ts +110 -0
- package/src/commands/ralph/task/remove.ts +62 -0
- package/src/config/context.ts +7 -0
- package/src/config/settings.ts +155 -0
- package/src/constants.ts +3 -0
- package/src/types/journal.ts +16 -0
- package/src/utils/anthropic/types.ts +158 -0
- package/src/utils/date-utils.test.ts +96 -0
- package/src/utils/date-utils.ts +54 -0
- package/src/utils/exec.ts +8 -0
- package/src/utils/git/gh-cli-wrapper.test.ts +14 -0
- package/src/utils/git/gh-cli-wrapper.ts +54 -0
- package/src/utils/git/git-wrapper.test.ts +26 -0
- package/src/utils/git/git-wrapper.ts +15 -0
- package/src/utils/git/git.ts +25 -0
- package/src/utils/render.test.ts +71 -0
- package/src/utils/render.ts +34 -0
- package/dist/index.d.mts +0 -1
- package/dist/index.mjs +0 -805
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import * as fs from "node:fs";
|
|
2
|
+
import * as path from "node:path";
|
|
3
|
+
import { Args, Flags } from "@oclif/core";
|
|
4
|
+
import { BaseCommand } from "../base.js";
|
|
5
|
+
import { DEFAULT_PROGRESS_FILE, resolveRalphPath } from "./lib/state.js";
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* Append progress message to ralph-progress.md (write-only, no read)
|
|
9
|
+
*/
|
|
10
|
+
export default class Progress extends BaseCommand {
|
|
11
|
+
static override description = "Append progress message (write-only, never reads file)";
|
|
12
|
+
|
|
13
|
+
static override examples = [
|
|
14
|
+
'<%= config.bin %> ralph progress "Completed user service implementation"',
|
|
15
|
+
'<%= config.bin %> ralph progress "Starting tests" --file custom-progress.md',
|
|
16
|
+
];
|
|
17
|
+
|
|
18
|
+
static override args = {
|
|
19
|
+
message: Args.string({
|
|
20
|
+
description: "Progress message to append",
|
|
21
|
+
required: true,
|
|
22
|
+
}),
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
static override flags = {
|
|
26
|
+
...BaseCommand.baseFlags,
|
|
27
|
+
file: Flags.string({
|
|
28
|
+
char: "f",
|
|
29
|
+
description: `Progress file path (default: ${DEFAULT_PROGRESS_FILE})`,
|
|
30
|
+
}),
|
|
31
|
+
};
|
|
32
|
+
|
|
33
|
+
async run(): Promise<void> {
|
|
34
|
+
const { args, flags } = await this.parse(Progress);
|
|
35
|
+
const ralphSettings = this.settings.settingsFile.settings.ralphSettings;
|
|
36
|
+
const progressFile = resolveRalphPath(flags.file, "progressFile", ralphSettings);
|
|
37
|
+
|
|
38
|
+
const timestamp = new Date().toISOString();
|
|
39
|
+
const line = `- [${timestamp}] ${args.message}\n`;
|
|
40
|
+
|
|
41
|
+
fs.mkdirSync(path.dirname(progressFile), { recursive: true });
|
|
42
|
+
fs.appendFileSync(progressFile, line);
|
|
43
|
+
}
|
|
44
|
+
}
|