gitpod-io / gitpod-io/leeway

Extend `vet` so that it produces a warning if any .gitignore files are in the srcs input to a package.

Open
#140 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Go
Stars
183
Forks
27
PR merge metrics
No merged PRs in 30d

Description

Is your feature request related to a problem? Please describe

  1. It's normal to add build artefacts to .gitignore
  2. Leeways' srcs globs makes it easy to include unintended files

Describe the behaviour you'd like

I'd like for vet to provide a warning if any files that are .gitignored are part of the expanded srcs.

Describe alternatives you've considered

Today you can probably manually check for this using a combination of leeway describe, jq and a bit of bash.

Additional context

See https://github.com/gitpod-io/gitpod/issues/14157

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the vet command and the code that expands package srcs globs; the payload does not name specific files or tests. Trace how .gitignore files are identified, then verify that vet warns when an ignored file appears in the expanded srcs and remains quiet otherwise.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
build-system, cli
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.