Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

`check-dist` can miss newly generated untracked files

Open Beginner friendly
#71 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
74/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
bash, github-actions
Domain
ci-cd

Research direction

The check lives in .github/workflows/check-dist.yml around line 48, where it runs git diff --ignore-space-at-eol over the dist path. Read how the step fails, then confirm that git ls-files --others --exclude-standard misses nothing the diff check does not already catch. Done means a newly generated untracked file under the dist path fails the job, while a whitespace-only change to a tracked file still passes. Verify both cases by running the step locally in a scratch repo.

Written by the indexing model from the issue text.

Description

The check in check-dist.yml counts lines from git diff --ignore-space-at-eol. Since git diff does not report untracked files, a build can create a new file under ${{ inputs.dist-path }} and the check may still pass.

Using git status --porcelain alone would detect untracked files, but it would also fail on tracked changes consisting only of trailing whitespace, which the current check intentionally ignores.

One option is to check for untracked files separately while keeping the existing whitespace handling for tracked changes:

if [ -n "$(git ls-files --others --exclude-standard -- "${{ inputs.dist-path }}")" ] ||
   ! git diff --ignore-space-at-eol --quiet -- "${{ inputs.dist-path }}"; then

This catches new, non-ignored untracked files as well as tracked modifications and deletions, while continuing to ignore end-of-line whitespace changes.

Dominant language
JavaScript
Stars
89
Forks
37
PR merge metrics
No merged PRs in 30d

Getting set up

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.

More from actions/reusable-workflows

All issues in actions/reusable-workflows

Similar issues

More JavaScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.