diff options
author | Unit 193 <unit193@ubuntu.com> | 2014-10-13 23:54:21 -0400 |
---|---|---|
committer | Unit 193 <unit193@ubuntu.com> | 2014-10-13 23:54:21 -0400 |
commit | 7b6b87655617da65c88b4e779fe11921a41fbb0a (patch) | |
tree | 31791277879ce6c6f0f4b0504d6355f5635792cc | |
parent | 821d590a7a25d7e42766d5d34c993b9baa4af965 (diff) | |
download | inxi-7b6b87655617da65c88b4e779fe11921a41fbb0a.tar.bz2 inxi-7b6b87655617da65c88b4e779fe11921a41fbb0a.tar.xz inxi-7b6b87655617da65c88b4e779fe11921a41fbb0a.tar.zst |
Imported Upstream version 2.2.15upstream/2.2.15
-rwxr-xr-x | inxi | 28 | ||||
-rwxr-xr-x | inxi.changelog | 17 |
2 files changed, 36 insertions, 9 deletions
@@ -1,8 +1,8 @@ #!/usr/bin/env bash ######################################################################## #### Script Name: inxi -#### Version: 2.2.14 -#### Date: 2014-09-26 +#### Version: 2.2.15 +#### Date: 2014-10-12 #### Patch Number: 00 ######################################################################## #### SPECIAL THANKS @@ -53,7 +53,7 @@ #### DEPENDENCIES #### * bash >=3.0 (bash); df, readlink, stty, tr, uname, wc (coreutils); #### gawk (gawk); grep (grep); lspci (pciutils); -#### ps, uptime (procps); find (findutils) +#### ps, find (findutils) #### * Also the proc filesystem should be present and mounted for Linux #### * Some features, like -M and -d will not work, or will work incompletely, #### if /sys is missing @@ -74,6 +74,7 @@ #### -G - full graphics output requires: glxinfo (mesa-utils); xdpyinfo (X11-utils); #### xrandr (x11-xserver-utils) #### -i - IP information, local/wan - ip (iproute) legacy, not used if ip present: ifconfig (net-tools) +#### -I - uptime (procps, check Debian if changed) #### -Ix - view current runlevel while not in X window system (or with -x): runlevel (sysvinit) #### -m - all systems, dmidecode, unless someone can find a better way. #### -M - for older systems whose kernel does not have /sys data for machine, dmidecode (dmidecode) @@ -1062,7 +1063,7 @@ check_required_apps() eval $LOGFS local app_name='' # bc removed from deps for now - local depends="df gawk grep ps readlink tr uname uptime wc" + local depends="df gawk grep ps readlink tr uname wc" if [[ -z $BSD_TYPE ]];then depends="$depends lspci" @@ -2066,7 +2067,6 @@ check_recommends_items() sed:sed~sed~sed~:string_replace tr:coreutils~coreutils~coreutils~:character_replace uname:uname~coreutils~coreutils~:kernel_data - uptime:procps~procps~procps~: wc:coreutils~coreutils~coreutils~:word_character_count ' local x_recommends=' @@ -2087,6 +2087,7 @@ check_recommends_items() modinfo:module-init-tools~module-init-tools~module-init-tools~:-Ax,-Nx_module_version runlevel:sysvinit~sysvinit~systemd~:-I_runlevel sudo:sudo~sudo~sudo~:-Dx_hddtemp-user;-o_file-user + uptime:procps~procps~procps~:-I_uptime_(check_which_package_owns_Debian) ' local downloaders=" @@ -10380,11 +10381,14 @@ get_unmounted_partition_filesystem() get_uptime() { eval $LOGFS + local uptime_value='' ## note: removing gsub(/ /,"",a); to get get space back in there, goes right before print a - local uptime_value="$( uptime | gawk '{ - a = gensub(/^.*up *([^,]*).*$/,"\\1","g",$0) - print a - }' )" + if type -p uptime &>/dev/null;then + uptime_value="$( uptime | gawk '{ + a = gensub(/^.*up *([^,]*).*$/,"\\1","g",$0) + print a + }' )" + fi echo "$uptime_value" log_function_data "uptime_value: $uptime_value" eval $LOGFE @@ -10912,6 +10916,9 @@ print_short_data() local short_data='' i='' b_background_black='false' local memory=$( get_memory_data ) local up_time="$( get_uptime )" + if [[ -z $up_time ]];then + up_time='N/A - missing uptime?' + fi # set A_CPU_CORE_DATA get_cpu_core_count @@ -11872,6 +11879,9 @@ print_info_data() local memory="$( get_memory_data )" local processes=$(( $( wc -l <<< "$Ps_aux_Data" ) - 1 )) local up_time="$( get_uptime )" + if [[ -z $up_time ]];then + up_time='N/A - missing uptime?' + fi local patch_version_number=$( get_patch_version_string ) local gcc_installed='' gcc_others='' closing_data='' diff --git a/inxi.changelog b/inxi.changelog index 9b812b9..3ceea75 100755 --- a/inxi.changelog +++ b/inxi.changelog @@ -1,4 +1,21 @@ ===================================================================================== +Version: 2.2.15 +Patch Version: 00 +Script Date: 2014-10-12 +----------------------------------- +Changes: +----------------------------------- +New version, tarball. Debian has for some reason broken procps / uptime support, for +as of yet unknown reasons, so rather than wait to see the bug resolved, I'm just removing +uptime as a depenendency, though this is a short term hack only because we don't know +why it was removed from procps or if that was just a mistake, or if other things as well might +be vanishing from procps. Am leaving in however uname as dependency because inxi cannot +determine what platform it is when it starts without that. + +----------------------------------- +-- Harald Hope - Sun, 12 Oct 2014 12:07:03 -0700 + +===================================================================================== Version: 2.2.14 Patch Version: 00 Script Date: 2014-09-26 |