diff --git a/inxi b/inxi index 5f9885d..60743ab 100755 --- a/inxi +++ b/inxi @@ -1414,9 +1414,10 @@ get_partition_data() /\/$|\/boot$|\/var$|\/home$/ { print $NF "," $(NF - 4) "," $(NF - 3) "," $(NF - 1) }' ) - # now add the swap partition, this doesn't show percent used, someone can figure that in the future + # now add the swap partition data, doesn't show percent used, someone can figure that in the future + # don't want to show swap files, just partitions $( swapon -s | gawk ' - /\dev\/[hs]d[a-z]/ { + /^\/dev\/[hs]d[a-z]/ { size = sprintf( "%.2f", $3*1024/1000**3 ) print $1 "," size "GB,,,swap" }' ) )