Minor changes
This commit is contained in:
parent
b68b16c472
commit
1bee84a7ec
1 changed files with 2 additions and 3 deletions
|
@ -173,6 +173,8 @@ ensure base64
|
|||
[ "$ACTION" == "dump" ] && { sysdump; exit 0; }
|
||||
|
||||
# Setting up dump file
|
||||
ensure awk
|
||||
ensure jq
|
||||
[ $(grep -c "${DUMP_DELIMITER}" "$1") -ne 0 ] && cleandump "$1"
|
||||
# Setup safegetentry
|
||||
DUMP_FILE="$1"
|
||||
|
@ -183,8 +185,6 @@ DUMP_ENTRIES=$(cat "${DUMP_FILE}"|jq -r "keys[]";)
|
|||
# Parse dump file
|
||||
if [ "$ACTION" == "parse" ]
|
||||
then
|
||||
ensure jq
|
||||
file=$1
|
||||
if [ $# -gt 1 ]
|
||||
then
|
||||
shift
|
||||
|
@ -204,7 +204,6 @@ fi
|
|||
# Summarize dump file
|
||||
if [ "$ACTION" == "summarize" ]
|
||||
then
|
||||
ensure jq
|
||||
OS_RELEASE=$(safegetentry /etc/os-release)
|
||||
CPU_INFO=$(safegetentry /proc/cpuinfo)
|
||||
MEM_INFO=$(safegetentry /proc/meminfo)
|
||||
|
|
Loading…
Add table
Reference in a new issue