mirror of
https://dev.iopsys.eu/feed/iopsys.git
synced 2025-12-10 07:44:50 +01:00
self-diagnostics: Fix rpcd scripts
This commit is contained in:
parent
2e8a62001e
commit
5f255090f5
2 changed files with 15 additions and 4 deletions
|
|
@ -1,7 +1,7 @@
|
||||||
include $(TOPDIR)/rules.mk
|
include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_NAME:=self-diagnostics
|
PKG_NAME:=self-diagnostics
|
||||||
PKG_VERSION:=1.0.8
|
PKG_VERSION:=1.0.9
|
||||||
PKG_RELEASE:=1
|
PKG_RELEASE:=1
|
||||||
|
|
||||||
PKG_LICENSE:=GPL-2.0-only
|
PKG_LICENSE:=GPL-2.0-only
|
||||||
|
|
|
||||||
|
|
@ -11,17 +11,28 @@ case "$1" in
|
||||||
case "$2" in
|
case "$2" in
|
||||||
generate)
|
generate)
|
||||||
read -t 1 -r input
|
read -t 1 -r input
|
||||||
|
local out
|
||||||
|
|
||||||
json_load "${input}"
|
json_load "${input}"
|
||||||
json_get_var modules modules
|
json_get_var modules modules
|
||||||
if [ -z "${modules}" ]; then
|
if [ -z "${modules}" ]; then
|
||||||
${BIN} -j
|
out="$(${BIN} -j)"
|
||||||
else
|
else
|
||||||
${BIN} -j -m "${modules}"
|
out="$(${BIN} -j -m "${modules}")"
|
||||||
|
fi
|
||||||
|
if [ -z "${out}" ]; then
|
||||||
|
echo '{}'
|
||||||
|
else
|
||||||
|
echo "${out}"
|
||||||
fi
|
fi
|
||||||
;;
|
;;
|
||||||
list)
|
list)
|
||||||
${BIN} -j -l
|
out="$(${BIN} -j -l)"
|
||||||
|
if [ -z "${out}" ]; then
|
||||||
|
echo '{}'
|
||||||
|
else
|
||||||
|
echo "${out}"
|
||||||
|
fi
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
;;
|
;;
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue