From c1fe45f28679107039a6507af93ea0ce6ee7957f Mon Sep 17 00:00:00 2001 From: inxi-svn Date: Wed, 14 Oct 2009 22:53:34 +0000 Subject: [PATCH] trying a bug fix for devBase partition info --- inxi | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/inxi b/inxi index 50dcb16..0f4d89c 100755 --- a/inxi +++ b/inxi @@ -2908,6 +2908,10 @@ get_partition_data() } getline } + # next set devBase if it didn not get set above here + ( $1 ~ /^\/dev\// ) && ( devBase == "" ) { + devBase=gensub( /^(\/dev\/)(.+)$/, "\\2", 1, $1 ) + } # this handles yet another fredforfaen special case where a mounted drive # has the search string in its name $NF ~ /^\/$|^\/boot$|^\/var$|^\/home$|^\/tmp$|^\/usr$/ { @@ -3098,6 +3102,7 @@ get_repo_data() { local repo_file='' repo_data_working='' local apt_file='/etc/apt/sources.list' yum_repo_dir='/etc/yum.repos.d/' yum_conf='/etc/yum.conf' + local pacman_conf='/etc/pacman.conf' pacman_repo_dir='/etc/pacman.d/' if [[ -f $apt_file || -d $apt_file.d ]];then REPO_DATA="$( grep -Esv '(^[[:space:]]*$|^[[:space:]]*#)' $apt_file $apt_file.d/*.list )" @@ -3172,6 +3177,10 @@ $repo_data_working" fi done REPO_FILE_ID='yum repos' + # note that pacman/arch mirrorlist file has all the mirrors on it, so it + # won't work for this feature, the output would be largely meaningless, and far too long +# elif [[ -f $pacman_file || -d $pacman_repo_dir ]];then +# REPO_FILE_ID='yum repos' fi }