mrtazz / checkmake

experimental linter/analyzer for Makefiles
MIT License
1.02k stars 44 forks source link

Make Makefile argument optional for easier use from tools. #81

Open michael-delarue-axomic opened 1 year ago

michael-delarue-axomic commented 1 year ago

This seems to solve problems with running checkmake from pre-commit. It very simply makes the Makefile argument optional which means that checkmake doesn't seem to run. (see also https://github.com/mrtazz/checkmake/issues/80 and some comments on other (closed) issues (e.g. https://github.com/mrtazz/checkmake/pull/69)

Checklist

Not all of these might apply to your change but the more you are able to check the easier it will be to get your contribution merged.

no unit test yet since this basically does nothing. Might investigate learning how to do that if considered worthwhile.

michael-delarue-axomic commented 1 year ago

According to the pre-commit documentation for adding new hooks the default is not to run hooks when there are no files to be checked and the checkmake hook configuration does not override this, so I am not really sure why this is helping, but it has.

colindean commented 1 year ago

Can you show the output you're seeing when it fails? I've used checkmake at rev c047d51fe0a08be186dc0c734151793924ebb249 for many months now without a problem across more than a dozen repos.

mrtazz commented 10 months ago

it would be good to have a more detailed description here of what exactly fails and how this is fixing it. Especially since there are reports where things are working.