toolroll 0.9.107 → 0.9.108

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.
@@ -29,7 +29,7 @@ export async function welcomeHere(store, databaseFile, now, options = {}) {
29
29
  return { model, projects: repos };
30
30
  }
31
31
  export const WELCOME_STEPS = ["agent", "project", "task"];
32
- export function welcomeStepLines(model, key) {
32
+ export function welcomeStepLines(model, key, sample = null) {
33
33
  const mark = (done) => (done ? "Done" : "To do");
34
34
  const lines = [];
35
35
  if (key === "agent") {
@@ -48,8 +48,12 @@ export function welcomeStepLines(model, key) {
48
48
  lines.push(`2. Project · ${mark(model.project.done)}`);
49
49
  for (const one of model.project.projects.slice(0, 3))
50
50
  lines.push(` ${one.name} ${one.path}`);
51
- if (model.project.projects.length === 0)
52
- lines.push(" Add a git repository: run `toolroll repos add <folder>`, or `toolroll --web` and choose one.");
51
+ const offer = model.project.projects.length === 0 && model.project.sample !== null ? sample : null;
52
+ const addOwn = "a git repository: run `toolroll repos add <folder>`, or `toolroll --web` and choose one.";
53
+ if (offer === "key")
54
+ lines.push(" s Try the sample project", ` Or add ${addOwn}`);
55
+ else if (model.project.projects.length === 0)
56
+ lines.push(` Add ${addOwn}`, ...offer === "command" ? [" Or try the sample project: run `toolroll welcome sample`."] : []);
53
57
  else if (model.project.notTakingWork)
54
58
  lines.push(" Tasks can't start yet: nothing on this computer is taking work. Run `toolroll`.");
55
59
  }
@@ -65,6 +69,9 @@ export function welcomeStepLines(model, key) {
65
69
  }
66
70
  return lines;
67
71
  }
68
- export function welcomeLines(model) {
69
- return [model.left === 0 ? "Setup is done." : `${model.left} ${model.left === 1 ? "step" : "steps"} left.`, "", ...WELCOME_STEPS.flatMap(key => welcomeStepLines(model, key))];
72
+ export function welcomeLines(model, sample = null) {
73
+ return [model.left === 0 ? "Setup is done." : `${model.left} ${model.left === 1 ? "step" : "steps"} left.`, "", ...WELCOME_STEPS.flatMap(key => welcomeStepLines(model, key, sample))];
74
+ }
75
+ export function sampleOffered(model, localOn, demo) {
76
+ return localOn && !demo && model.project.projects.length === 0 && model.project.sample !== null;
70
77
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "toolroll",
3
- "version": "0.9.107",
3
+ "version": "0.9.108",
4
4
  "description": "Your agents build. You decide. A control plane for coding agents — Claude Code, Codex, Gemini: approve the exact scope once, get results back Ready with the diff, the passing check and screenshots. Runs on your machine.",
5
5
  "directories": {
6
6
  "doc": "docs"