mirror of
https://github.com/AuxXxilium/arc.git
synced 2024-11-23 23:39:54 +07:00
arc-functions: fix missing
Signed-off-by: AuxXxilium <info@auxxxilium.tech>
This commit is contained in:
parent
7dddfe463c
commit
48c66303af
@ -1845,6 +1845,7 @@ function editGrubCfg() {
|
||||
###############################################################################
|
||||
# Grep Logs from dbgutils
|
||||
function greplogs() {
|
||||
rm -rf "${TMP_PATH}/logs" "${TMP_PATH}/logs.tar.gz"
|
||||
MSG=""
|
||||
SYSLOG=0
|
||||
DSMROOTS="$(findDSMRoot)"
|
||||
@ -1868,7 +1869,7 @@ function greplogs() {
|
||||
fi
|
||||
|
||||
PSTORE=0
|
||||
if [ -n "$(ls /sys/fs/pstore)" ]; then
|
||||
if [ -n "$(ls /sys/fs/pstore 2>/dev/null)" ]; then
|
||||
mkdir -p "${TMP_PATH}/logs/pstore"
|
||||
cp -rf /sys/fs/pstore/* "${TMP_PATH}/logs/pstore"
|
||||
zlib-flate -uncompress </sys/fs/pstore/*.z >"${TMP_PATH}/logs/pstore/ps.log" 2>/dev/null
|
||||
@ -1896,16 +1897,16 @@ function greplogs() {
|
||||
MSG+="3. Reboot into Arc and go to this option.\n"
|
||||
fi
|
||||
|
||||
rm -f "${TMP_PATH}/logs.tar.gz"
|
||||
tar -czf "${TMP_PATH}/logs.tar.gz" -C "${TMP_PATH}" logs
|
||||
|
||||
if [ -z "${SSH_TTY}" ]; then # web
|
||||
mv -f "${TMP_PATH}/logs.tar.gz" "/var/www/data/logs.tar.gz"
|
||||
URL="http://$(getIP)/logs.tar.gz"
|
||||
MSG+="Please visit ${URL} to download the logs,\nAnd go to Github or Discord to create an issue and upload the logs."
|
||||
else
|
||||
sz -be -B 536870912 "${TMP_PATH}/logs.tar.gz"
|
||||
MSG+="Please go to Github or Discord to create an issue and upload the logs."
|
||||
if [ -n "$(ls -A ${TMP_PATH}/logs 2>/dev/null)" ]; then
|
||||
tar -czf "${TMP_PATH}/logs.tar.gz" -C "${TMP_PATH}" logs
|
||||
if [ -z "${SSH_TTY}" ]; then # web
|
||||
mv -f "${TMP_PATH}/logs.tar.gz" "/var/www/data/logs.tar.gz"
|
||||
URL="http://$(getIP)/logs.tar.gz"
|
||||
MSG+="Please via ${URL} to download the logs,\nAnd go to Github or Discord to create an issue and upload the logs."
|
||||
else
|
||||
sz -be -B 536870912 "${TMP_PATH}/logs.tar.gz"
|
||||
MSG+="Please go to Github or Discord to create an issue and upload the logs."
|
||||
fi
|
||||
fi
|
||||
dialog --backtitle "$(backtitle)" --colors --title "Grep Logs" \
|
||||
--msgbox "${MSG}" 0 0
|
||||
|
Loading…
Reference in New Issue
Block a user