[Abcde-users] Correction - Capitalize Letter for Default Option

Roger rogerx.oss at gmail.com
Wed May 1 22:52:03 BST 2013


This basically looks like a chicken before the egg syndrom. ;-)

In other words, printing the choices before knowing what the preferred choice will be.

Only the stdout choices are printed after knowing the possibly preferred 
options, instead of printing them before.

The capitalized letters now indicate the preferred or common choice.  The old 
style parenthesis (y) and (n) is preserved to further indicate some internal 
switching is used, so as not to alert users when they start noticing the (n) 
and (y) oddly changing on them after recursive usage of abcde. ;-)


--      echo -n "Edit selected CDDB data? [y/n] (" >&2
++      echo -n "Edit selected CDDB data? " >&2
 
       if [ "$INTERACTIVE" = "y" ]; then
                if [ "$UNKNOWNDISK" = "y" ]; then
--                      echo -n "y): " >&2
++                      echo -n "[Y/n] (y): " >&2
                        read EDITCDDB
                        [ "$EDITCDDB" != "n" ] && EDITCDDB=y
                else    
--                      echo -n "n): " >&2
++                      echo -n "[y/N] (n): " >&2
                        read EDITCDDB
                fi
        else    
--              echo "n): n" >&2
++              echo "[y/N] (n): n" >&2
                EDITCDDB=n

If this looks good, I'll submit a patch, or anybody can freely grab this task.

(I should grab the CVS/SVN/GIT version.)

-- 
Roger
http://rogerx.freeshell.org/



More information about the Abcde-users mailing list