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
Remove version argument check from initramfs cleanup script #3859
Conversation
The version argument is not used by the script anymore, hence the check is obsolete. Additionally make use of the currently unused defined MOD_DIR variable. Signed-off-by: MichaIng <micha@dietpi.com>
@MichaIng What code did you use to debug this fix? |
It's not a fix, just a cleanup after the last rework of this script. I ran it once on console with a fake initramfs image, nothing more. The change otherwise is trivial: Before the last rework, Why are you asking, is there an issue with this change? |
Thanks. I understood. You did the right thing, but you didn't finish it. We have another such script. It also needs to be fixed. But this correction and the subsequent one require additional checks. You don't have to worry. I'll check it out and let you know when I make the changes. |
Ah you're right, I missed the postrm one: https://github.com/armbian/build/blob/master/packages/bsp/common/etc/kernel/postrm.d/xx-initramfs-cleanup It can be changed the same way, let me know if I should open a PR accordingly. |
No you don't need to.
If the script is run without arguments, it should not be executed! You removed this check. This alerted me. |
The way the initramfs images are cleaned now, is actually always safe to do, regardless how/when the script is executed, isn't it? |
Give me time to check. |
Description
The version argument is not used by the script anymore, hence the check is obsolete.
Additionally make use of the currently unused defined MOD_DIR variable.
Jira reference number [AR-9999]
How Has This Been Tested?
Running the script locally, the change otherwise is trivial.
Checklist: