Add a hook to run shellcheck on all "runs" steps in melange pipelines#1
Add a hook to run shellcheck on all "runs" steps in melange pipelines#1dannf wants to merge 1 commit intochainguard-dev:mainfrom
Conversation
Signed-off-by: dann frazier <dann.frazier@chainguard.dev>
|
Love the idea, and thanks for the implementation! I'm curious about setup.py and setup.cfg, such as if they should be in a subfolder or shared between multiple hooks. Perhaps we could build some documentation here too. |
smoser
left a comment
There was a problem hiding this comment.
This looks really well done.
my only thoughts are
- python dependencies - how do you assert a sane environment ? you also have to somehow deliver / assert
shellcheck. (maybe you've solved that and I just don't understand. seems like a company that builds containers here could help.) - would having melange do this be sane? that gets you out having to deliver the python stuff at least. a 'melange check' command could be good and easily callable.
|
Re # 1: Pre-commit does handle setting up a Python environment and managing dependencies. Some more info here: https://pre-commit.com/#python This also leads into my question a bit, seems we will want our Python hook stuff to be at the top level.
|
Perhaps. I went with |
Yeah, I think this is required for python hooks, which I see you've also discovered below. fwiw, I used the upstream |
Even though this is an easy option, I do like the hint of using a guarded container instead. I'll experiment with that. |
I've now added a |
|
for some reason this PR is wedged. |
No description provided.