Skip to content

feat: status-bar item with the errors-ai.log error count #3

Description

@GabrielBBaldez

Add a status-bar item showing how many error reports are in the current errors-ai.log, so you notice new errors without opening the view.

What to do

In src/extension.ts:

  1. Create a vscode.StatusBarItem (align left) in activate(), e.g. text $(bug) 3, tooltip stacktale: 3 error reports.
  2. Update its text whenever the reports refresh — the provider already re-reads on the FileSystemWatcher event and on the stacktale.refresh command; hook the count update into the same place (the count is parseReports(...).length).
  3. Set the item's command to stacktale.reports.focus (reveals the view) so a click jumps to the list.
  4. Hide the item when there's no errors-ai.log in the workspace; show it when one is found. Remember to context.subscriptions.push(...) it.

How to verify

F5 to launch the Extension Development Host, open a project with an errors-ai.log, and confirm the count appears and updates as reports are added. npm run compile must stay clean (strict TS).

File: src/extension.ts (plus a line in package.json only if you choose to gate visibility with a when context).

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions