Skip to content

fix(make): discover lowercase makefile and GNUmakefile - #531

Open
DazorPlasma wants to merge 2 commits into
stevearc:masterfrom
DazorPlasma:fix/makefile-name-discovery
Open

DazorPlasma wants to merge 2 commits into
stevearc:masterfrom
DazorPlasma:fix/makefile-name-discovery

Conversation

@DazorPlasma

Copy link
Copy Markdown

The Make provider currently searches only for Makefile, so projects using the conventional lowercase makefile or GNUmakefile produce no task templates even though make works in those directories.

Recognize all three default GNU Make filenames, in the order GNUmakefile, makefile, Makefile, while preserving the upward search for the closest directory. This also makes the provider's cache key match the file that make -rRpq reads when multiple default filenames exist.

Add regression tests using real Make target discovery for each filename, filename precedence, discovery from subdirectories, and missing Makefiles. The discovery tests also verify that recipes are not executed.

Validation on Neovim 0.12.5:

  • Full test suite: 90 tests passed, including 7 new regression tests. Five of the new tests failed against the original provider.
  • stylua --check lua tests: passed.
  • luacheck lua tests: passed (0 warnings/errors; repository configuration excludes tests).
  • Repository Lua type checking with the neotest and nvim-dap libraries: passed.
  • git diff --check: passed.

@github-actions
github-actions Bot requested a review from stevearc October 9, 2026 19:12
@DazorPlasma
DazorPlasma force-pushed the fix/makefile-name-discovery branch from 7287350 to 318dc7b Compare October 9, 2026 19:37
@DazorPlasma
DazorPlasma force-pushed the fix/makefile-name-discovery branch from 7af988a to 24b65ec Compare October 9, 2026 19:37
@DazorPlasma
DazorPlasma marked this pull request as ready for review October 9, 2026 19:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant