UNPKG

scai

Version:

> AI-powered CLI tool for commit messages **and** pull request reviews — using local models.

17 lines (16 loc) 522 B
import columnify from "columnify"; export function styleOutput(summaryText) { const terminalWidth = process.stdout.columns || 80; // You can control wrapping here const formatted = columnify([{ Summary: summaryText }], { columnSplitter: ' ', maxLineWidth: terminalWidth, config: { Summary: { maxWidth: Math.floor((terminalWidth * 2) / 3), // Use 2/3 width like before align: "left", }, }, }); return formatted; }