vscode-coverage-gutters icon indicating copy to clipboard operation
vscode-coverage-gutters copied to clipboard

Add option to show only uncovered lines

Open Tadaboody opened this issue 7 years ago • 10 comments

Feature Request:

Usually I only care if a line is uncovered. seeing all the green lines is more of a feel-good thing 😜, so I'd like the option to turn them off.

This will also let me leave the extension almost always watching while still having lots of places to add breakpoints while #95 is still a thing.

Tadaboody avatar Oct 02 '18 10:10 Tadaboody

https://github.com/ryanluker/vscode-coverage-gutters#tips-and-tricks you can do just that now via the settings, let me know if that helps!

ryanluker avatar Oct 02 '18 15:10 ryanluker

My problem isn't putting breakpoints. I want the option to only view the red spots in the gutter - Only highlight the uncovered lines

Tadaboody avatar Oct 02 '18 18:10 Tadaboody

@Tadaboody ahh gotcha, you can do this by modifying the settings (and restarting VS Code afterwords) to have it just show uncovered in the gutter by setting the other coverage type's color to nothing. This disables the decorations (vscode's terminology for the colorations that show up on the line and in the gutter) for full and partial, leaving you with the uncovered. https://github.com/ryanluker/vscode-coverage-gutters/blob/master/package.json#L112-L126 https://github.com/ryanluker/vscode-coverage-gutters/blob/master/package.json#L52-L111

ryanluker avatar Oct 03 '18 01:10 ryanluker

I tried this. it work, if a bit cumbersome.

Some of the settings are described/named in a bit of a confusing way, and the combination of #132 and #169 make configuring not very user-friendly.

Tadaboody avatar Oct 03 '18 09:10 Tadaboody

Actually looking at it again - I'm not sure your solution works

Tadaboody avatar Oct 03 '18 09:10 Tadaboody

@Tadaboody just trying to flesh out this ticket a bit more and I am looking for some feedback on the approaches I will outline below.

I am thinking there will need to be new extension settings to handle turning off or on certain types of coverage (ie full, partial or none). Would you expect these to be granular per feature? For example turn off the full coverage for just the gutters or turn off full coverage altogether?

ryanluker avatar Nov 03 '18 19:11 ryanluker

@Tadaboody Still looking for more input, from you, on this one (see my last comment). In the meantime I am going to move this out of the 2.3.0 release and into the backlog until it is fleshed out 👍 .

ryanluker avatar Nov 18 '18 19:11 ryanluker

@ryanluker Personally I think that making it granular per-feature would clutter the settings too much. Instead a simple checkbox for each coverage type would be great.

iansan5653 avatar Jan 25 '19 14:01 iansan5653

Clearly that we need a solution to make the coverage information more subtle, as current behavior makes it hard to edit the code due to being too in-your-face.

ssbarnea avatar May 17 '23 09:05 ssbarnea

Clearly that we need a solution to make the coverage information more subtle, as current behavior makes it hard to edit the code due to being too in-your-face.

Thanks for the comment @ssbarnea, have you tried tinkering with the colours or some of the options in the extension settings?

Currently, the latest version of vscode also reduced the gutter size so maybe having just the gutter and no line or ruler visuals would be better for you?

        "coverage-gutters.showLineCoverage": {
          "type": "boolean",
          "default": false,
          "description": "show or hide the line coverage"
        },
        "coverage-gutters.showRulerCoverage": {
          "type": "boolean",
          "default": false,
          "description": "show or hide the ruler coverage"
        },
        "coverage-gutters.showGutterCoverage": {
          "type": "boolean",
          "default": true,
          "description": "show or hide the gutter coverage"
        },

ryanluker avatar May 22 '23 16:05 ryanluker