added markdown linter in format.sh file#182
added markdown linter in format.sh file#182Vineet1101 wants to merge 2 commits intop4lang:masterfrom
Conversation
Signed-off-by: Vineet1101 <vineetgoel692@gmail.com>
cba7037 to
f2468e8
Compare
|
@qobilidop @smolkaj can you please review this |
|
Thanks for the PR, @Vineet1101! Have you considered using some off-the-shelve formatter? Using something standard and proven seems a bit more maintainable than rolling our own. There are a lot of corner cases to consider, so I’d rather not reinvent the wheel and maintain our own solution going forward. |
ok I will check that and update the code |
|
Hey @smolkaj, a small doubt. I have 2 ways to get this done:-
In approach 1, the formatter will not be able to run locally, and if you want that also, I can replace format.sh with the Python-based formatter |
Signed-off-by: Vineet1101 <vineetgoel692@gmail.com>
|
Since this repo has only ~2 markdown files, we need a very low-cost/low-maintainance solution. Otherwise we may be better off without a formatter. I worry proposal 1 may be worse than no formatter since we’re now introducing an additional barrier for contributors; we want to keep things very low friction and easy. https://github.com/hukkin/mdformat could perhaps work, but it is not yet available in the BCR. Without that, I’m not sure how reliably it can be used/installed across various machines? |
I was also thinking of using this |
|
In my opinion we can go with https://github.com/hukkin/mdformat because of this "Mdformat is pure Python code! Python is pre-installed on macOS and virtually any Linux distribution, meaning that typically little to no additional installations are required to run mdformat. This argument also holds true when using together with pre-commit (also Python). Prettier on the other hand requires Node.js/npm." |
This PR solves #169