Skip to content

Commit 1163d81

Browse files
committed
docs(plans): address PR #73 review — fix deprecated set-output + MD040
CodeRabbit fact-checked both findings against current code; both real. - T1 (Major): replaced deprecated `::set-output` (deprecated 2022-10 per GitHub changelog) with the `GITHUB_OUTPUT` environment file approach in the package-manager-detector wrapper sketch (Q2 resolution). Used `appendFileSync(process.env.GITHUB_OUTPUT, ...)` per current GitHub Actions docs. - T2 (Minor, MD040): added `text` language tag to the Q3 resolution pseudo-code block so markdownlint-cli2 stops flagging the unlanguaged fence.
1 parent d549260 commit 1163d81

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

docs/plans/github-marketplace-action.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,11 +81,13 @@ These are the design questions the plan-PR resolves before impl starts. Each get
8181
```javascript
8282
import { detect } from "package-manager-detector/detect";
8383
import { resolveCommand } from "package-manager-detector/commands";
84+
import { appendFileSync } from "node:fs";
8485
8586
const pm = await detect();
8687
const agent = pm?.agent ?? "npm";
8788
// resolveCommand handles `npm exec` vs `pnpm exec` vs `bun x` vs `yarn dlx` — Q3 lookup-table for free
88-
console.log(`::set-output name=agent::${agent}`);
89+
// Write to GITHUB_OUTPUT env file (`::set-output` deprecated since 2022-10).
90+
appendFileSync(process.env.GITHUB_OUTPUT, `agent=${agent}\n`);
8991
```
9092

9193
Precedence: `package-manager:` input still wins when set (overrides detection). When unset, the library's default strategy order applies. Multiple-lockfile case is handled by the library; we surface its result + log a warning if ambiguous.
@@ -98,7 +100,7 @@ These are the design questions the plan-PR resolves before impl starts. Each get
98100

99101
**Resolution: project-installed first, download-and-execute fallback.** Maps directly onto `package-manager-detector`'s two `resolveCommand` intents — `'execute-local'` (already installed) vs `'execute'` (download and run). No hand-rolled per-agent branching; the library resolves `npx` / `bunx` / `pnpm dlx` / `yarn dlx` itself.
100102

101-
```
103+
```text
102104
if version-input is set:
103105
intent = 'execute' # forced download with pinned version
104106
cli = resolveCommand(agent, 'execute', ['codemap@<version>'])

0 commit comments

Comments
 (0)