镜像来自
https://git.openwrt.org/project/luci.git
已同步 2025-01-18 23:45:02 +00:00
734442a10b
Commit includes wrapper syslog in /usr/libexec. If a log file is configured, the output of this file is displayed. Otherwise the output of logread is displayed. Signed-off-by: Christian Korber <ckorber@tdt.de>
21 line
267 B
Bash
Executable file
21 line
267 B
Bash
Executable file
#!/bin/sh
|
|
|
|
. /lib/functions.sh
|
|
|
|
main() {
|
|
local log_file
|
|
|
|
log_file="$(uci_get system @system[0] log_file "")"
|
|
if [ -f "$log_file" ]; then
|
|
cat "$log_file"
|
|
return
|
|
fi
|
|
|
|
if [ -f /sbin/logread ]; then
|
|
/sbin/logread -e ^
|
|
else
|
|
/usr/sbin/logread -e ^
|
|
fi
|
|
}
|
|
|
|
main
|