Skip to content

Commit bedebf1

Browse files
committed
fix(cli): name the user's own launcher in the init remedies
1 parent 47527c7 commit bedebf1

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

‎packages/cli/src/filesystem/migrations/0005-rule-directories.ts‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import { dirname, join } from "node:path";
1010

1111
import type { Migration } from "../types";
1212
import { CLIError } from "../../util/cli-error";
13-
import { buildInvocation } from "../../util/invocation";
13+
import { getCliPrefix } from "../../util/package-manager";
1414
import { escapeRegExp } from "../../util/regex";
1515
import {
1616
ENGINES,
@@ -83,7 +83,7 @@ async function assertRootIsFree(directory: string): Promise<void> {
8383
`Cannot create the rule directories: .taskless/${RULES_DIRECTORY}/ still contains ` +
8484
`${stray.join(", ")} from the pre-migration layout. Move ` +
8585
`${stray.length === 1 ? "it" : "them"} into .taskless/sg/rules/ by hand, ` +
86-
`then run \`${buildInvocation()} init\` again.`,
86+
`then run \`${getCliPrefix()} init\` again.`,
8787
"SCAFFOLD_CONFLICT"
8888
);
8989
}

‎packages/cli/src/rules/reconcile-marker.ts‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import { AST_GREP_VERSION, VALE_VERSION } from "./capabilities";
55
import { readManifest, writeManifest } from "../filesystem/manifest";
66
import { TASKLESS_DIRECTORY } from "./vale/formats";
77
import { CLIError } from "../util/cli-error";
8-
import { buildInvocation } from "../util/invocation";
8+
import { getCliPrefix } from "../util/package-manager";
99
import { compareVersions } from "../util/version-compare";
1010
import { getCliVersion } from "../wizard/intro";
1111

@@ -80,7 +80,7 @@ export async function recordReconciliation(
8080
// states this precondition; this is the code holding to it.
8181
if (!(await pathExists(tasklessDirectory))) {
8282
throw new CLIError(
83-
`No \`${TASKLESS_DIRECTORY}/\` in this project, so there are no rules to reconcile. Run \`${buildInvocation()} init\` to set it up before recording a reconciliation.`,
83+
`No \`${TASKLESS_DIRECTORY}/\` in this project, so there are no rules to reconcile. Run \`${getCliPrefix()} init\` to set it up before recording a reconciliation.`,
8484
"INVALID_INPUT"
8585
);
8686
}

0 commit comments

Comments
 (0)