package/openrc/sysv-rcs: fix shellcheck 0.10 warnings

* Explicitly set shell type. Shellcheck doesn't know OpenRC, but the
  script as such is POSIX shell.
* Override warnings not applicable in context.

Signed-off-by: Fiona Klute <fiona.klute@gmx.de>
Signed-off-by: Marcus Hoffmann <buildroot@bubu1.eu>
This commit is contained in:
Fiona Klute
2026-06-06 20:20:32 +02:00
committed by Marcus Hoffmann
parent b4884a2937
commit 3e2cc4e46f

View File

@@ -1,5 +1,7 @@
#!/sbin/openrc-run
# shellcheck shell=sh
# shellcheck disable=SC2034 # definition for OpenRC
description="start or stop sysv rc[S,K] scripts"
depend() {
@@ -17,6 +19,8 @@ start() {
}
stop() {
# we need to reverse the order here, sort -r would be no less fragile
# shellcheck disable=SC2045
for i in $(ls -r /etc/init.d/S??*); do
# Ignore dangling symlinks (if any).
[ -e "$i" ] || continue