diff --git a/inxi b/inxi index 22ec4ee..a5f31ce 100755 --- a/inxi +++ b/inxi @@ -3,7 +3,7 @@ #### Script Name: inxi #### version: 1.6.10 #### Date: June 17 2011 -#### Patch Number: 03 +#### Patch Number: 04 ######################################################################## #### SPECIAL THANKS ######################################################################## @@ -4550,7 +4550,10 @@ get_optical_drive_data() elif [[ -e /proc/ide/$disk/model ]];then vendor=$( cat /proc/ide/$disk/model 2>/dev/null | sed 's/^[[:space:]]\+//;s/[[:space:]]\+$//' ) fi - proc_cdrom="$( cat /proc/sys/dev/cdrom/info 2>/dev/null )" + if [[ $B_EXTRA_DATA == 'true' ]];then + proc_cdrom="$( cat /proc/sys/dev/cdrom/info 2>/dev/null )" + + fi item_string="$item_string,$vendor,$model,$rev_number" echo $item_string @@ -6694,8 +6697,6 @@ print_optical_drive_data() if [[ -z $drive_links ]];then drive_links='N/A' fi - - if [[ -n ${a_drives[2]} ]];then vendor=${a_drives[2]} if [[ -n ${a_drives[3]} ]];then @@ -6703,12 +6704,21 @@ print_optical_drive_data() fi fi if [[ -z $vendor ]];then - vendor='N/A' + if [[ -n ${a_drives[3]} ]];then + vendor=${a_drives[3]} + else + vendor='N/A' + fi fi drive_data="${C1}Optical${counter}:${C2} $drive_id ${C1}model:${C2} $vendor ${C1}dev-links:${C2} $drive_links" drive_data=$( create_print_line "$Line_Starter" "$drive_data" ) print_screen_output "$drive_data" Line_Starter=' ' + if [[ $B_EXTRA_DATA == 'true' ]];then + drive_data="${C1}Features:${C2} " + drive_data=$( create_print_line "$Line_Starter" "$drive_data" ) + print_screen_output "$drive_data" + fi done else :