bughunters 0.1.0 → 0.1.2
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.
- package/dist/bin.js +841 -383
- package/package.json +1 -1
- package/src/ui/app.js +8 -4
- package/src/ui/style.css +1 -0
package/package.json
CHANGED
package/src/ui/app.js
CHANGED
|
@@ -487,7 +487,7 @@ function renderUsage(usage) {
|
|
|
487
487
|
el('td', { text: count(Math.round((row.tokens.input + row.tokens.output) / Math.max(1, row.sessions))) }),
|
|
488
488
|
el('td', { text: row.tokens.listCostUsd ? money(row.tokens.listCostUsd) : '—' }),
|
|
489
489
|
])),
|
|
490
|
-
]) : el('p', { class: 'empty', text: 'No token usage yet. The API agents,
|
|
490
|
+
]) : el('p', { class: 'empty', text: 'No token usage yet. The API agents, claude (--output-format json), and codex (--json) report their tokens.' }),
|
|
491
491
|
]);
|
|
492
492
|
}
|
|
493
493
|
|
|
@@ -508,11 +508,15 @@ function title(text, aside) {
|
|
|
508
508
|
]);
|
|
509
509
|
}
|
|
510
510
|
|
|
511
|
-
|
|
511
|
+
const CI_WORDS = { pending: 'CI running', passed: 'CI green', failed: 'CI failed, fixing', 'gave-up': 'CI red' };
|
|
512
|
+
|
|
513
|
+
function githubChip({ kind, number, url, state, draft, ci }) {
|
|
512
514
|
const label = kind === 'pr' ? 'PR' : 'Issue';
|
|
513
515
|
const shown = state === 'open' && draft ? 'draft' : state;
|
|
516
|
+
const checks = state === 'open' || !state ? CI_WORDS[ci] : undefined;
|
|
514
517
|
return el('a', { href: url, target: '_blank', rel: 'noopener noreferrer',
|
|
515
|
-
class: `gh-chip gh-${shown || 'unknown'}
|
|
518
|
+
class: `gh-chip gh-${shown || 'unknown'}${checks ? ` ci-${ci}` : ''}`,
|
|
519
|
+
text: `${label} #${number}${shown ? ` · ${shown}` : ''}${checks ? ` · ${checks}` : ''}`,
|
|
516
520
|
onclick: (event) => event.stopPropagation() });
|
|
517
521
|
}
|
|
518
522
|
|
|
@@ -562,7 +566,7 @@ function renderOverview() {
|
|
|
562
566
|
data.patrol?.nextAt ? el('p', { class: 'muted',
|
|
563
567
|
text: `Next patrol at ${new Date(data.patrol.nextAt).toLocaleTimeString([], {
|
|
564
568
|
hour: '2-digit', minute: '2-digit',
|
|
565
|
-
})}`,
|
|
569
|
+
})}${data.patrol.commit ? ` · last tested commit ${data.patrol.commit.slice(0, 7)}` : ''}`,
|
|
566
570
|
}) : null,
|
|
567
571
|
]),
|
|
568
572
|
]);
|
package/src/ui/style.css
CHANGED
|
@@ -83,6 +83,7 @@ code, .mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-
|
|
|
83
83
|
.gh-open { color: var(--gh-open); }
|
|
84
84
|
.gh-merged { color: var(--gh-merged); }
|
|
85
85
|
.gh-closed { color: var(--gh-closed); }
|
|
86
|
+
.gh-chip.ci-failed, .gh-chip.ci-gave-up { color: var(--gh-closed); }
|
|
86
87
|
.github-summary { font-size: .8rem; margin-bottom: .75rem; }
|
|
87
88
|
|
|
88
89
|
.sev-critical { --sev: var(--critical); }
|