-
Notifications
You must be signed in to change notification settings - Fork 146
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve Makefiles for generating scanner documentation #950
Conversation
It is easier to maintain the location of directories at one place. Also use built in functions to find files w/ glob patterns instead of convoluted shell script magic. Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
Since macOS and maybe BSD does not support .ONESHELL for make targets we must removethis. To make the shell commands work ;\ must be appended to each line, except block open keywords such as 'then' or 'else'. This path also utilizes the SCANNERS_CHART_LIST variable instead of the find. Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
Jumping around with relative dirs is very brittle. Better pattern is to define a variable with absolute location and references this. Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
Also use absolute path to be more stable for refactorings. Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
Forunknown reason helm-docs need to be in the scanner dir. Maybe it assumes some files relative to the Chart.yaml Until I discovered this issue using the cd as workaround. Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
Because it is shell script anyway and editing shell script in Makefiles is tedious I decided to extract the code into a separate shell script. So we can invoke this from the make targets. AFAICS there is lots of duplicatedcode for hooks and parser. Seems to be nearly the same as for the scanners. So we may reuse thisscript. This will elad into a cleaner Makefile and less code to maintain. Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
Does not seem to work for me... Test process:
Relevant log snippet:
Let me know if I can help debug this in any way. |
ACK. I thought this was a general warning, but I cross checked on a Debian machine: No such warnings. I have no clue why it occurs because the printed filename is accessible and I have no idea why helm-docs can't open it. |
Maybe @J12934 has an idea what is going on there? |
@J12934 Also something I don't understand: Why is it necessary for |
110854c
to
4531c4d
Compare
Loglevel trace of |
2c8aa25
to
7711721
Compare
@malexmave Fixed! Would you please test on your machine? |
Works on my machine now 🥳 . However, only for scanner-docs, not for hook-docs. |
Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
…values Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
We log this anyway in the called shell script anddoes not need the info twice. Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
So we do not need to cd around. Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
helm-docs expets only a filename which is relative to the found Chart.yaml. So we simply add the 'docs' part. Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
f569c41
to
f255186
Compare
Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
f255186
to
f7e61f7
Compare
Signed-off-by: GitHub Actions <securecodebox@iteratec.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Works for me, and results are now also consistent with those obtained by the CI job.
Can you merge? You should have the rights. |
No description provided.