Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ on:
pull_request:
branches: [main]

permissions:
contents: read

jobs:
check:
runs-on: ubuntu-latest
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/token-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ on:
env:
NPM_TOKEN_EXPIRES: "2026-08-21"

permissions:
contents: read
issues: write

jobs:
check:
runs-on: ubuntu-latest
Expand Down
18 changes: 18 additions & 0 deletions packages/cli/src/lib/terminal-render.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,24 @@ describe('createTerminalRenderer', () => {
expect(capture.writes.join('')).toBe('# Summary\n\n- item\n');
});

it('strips markdown table separator rows and resists pathological inputs', () => {
const capture = createCapture(true);
const renderer = createTerminalRenderer(capture.output);

renderer.renderMarkdown(
['| Name | Value |', '| :--- | ---: |', '| foo | 1 |'].join('\n'),
);
const rendered = capture.writes.join('');
expect(rendered).not.toContain(':---');
expect(rendered).not.toContain('---:');

const pathological = `| |${' |'.repeat(26)}x|`;
const start = performance.now();
const capture2 = createCapture(true);
createTerminalRenderer(capture2.output).renderMarkdown(pathological);
expect(performance.now() - start).toBeLessThan(500);
});

it('renders preview panels and tool activity lines', () => {
const capture = createCapture(true);
const renderer = createTerminalRenderer(capture.output);
Expand Down
2 changes: 1 addition & 1 deletion packages/cli/src/lib/terminal-render.ts
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ function isTableLine(line: string): boolean {

function formatTable(lines: string[]): string[] {
const rows = lines
.filter((line) => !/^\|\s*[: -]+(\|\s*[: -]+)+\|$/.test(line))
.filter((line) => !/^\|[ \t:-]+(\|[ \t:-]+)+\|$/.test(line))
.map((line) =>
line
.slice(1, -1)
Expand Down
14 changes: 6 additions & 8 deletions packages/retarget-action/dist/index.js

Large diffs are not rendered by default.

18 changes: 2 additions & 16 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pnpm-workspace.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ overrides:
"postcss@<8.5.10": "8.5.15"
"rollup@>=4.0.0 <4.59.0": "4.59.0"
"smol-toml@<1.6.1": "1.6.1"
"undici@>=6.0.0 <6.24.0": "6.24.0"
"undici@<6.24.0": "6.24.0"
"undici@>=7.0.0 <7.24.0": "7.24.0"
"vite@>=7.0.0 <=7.3.1": "7.3.2"
"ws@>=8.0.0 <8.20.1": "8.20.1"
Expand Down
Loading