Page 1 of 3 123 LastLast
Results 1 to 10 of 22

Thread: Green [ ok ] messages

  1. #1
    Join Date
    Dec 2004
    Beans
    3
    Distro
    Dapper Drake Testing/

    Green [ ok ] messages

    I was annoyed that during boot, only the status messages showing [fail] got coloured (red), so I created a very simple patch that makes the [ ok ] messages appear in green.

    The patch applies to /lib/lsb/init-functions

    Code:
    --- init-functions.orig 2004-12-18 23:45:08.756780424 +0100
    +++ init-functions      2004-12-18 23:44:52.699221544 +0100
    @@ -190,9 +190,10 @@
             END=`$TPUT hpa $COL`
             START=`$TPUT hpa 0`
             RED=`$TPUT setaf 1`
    +       GREEN=`$TPUT setaf 2`
             NORMAL=`$TPUT op`
             if [ $1 -eq 0 ]; then
    -            echo "$UP$END[ ok ]"
    +            echo "$UP$END[ ${GREEN}ok${NORMAL} ]"
             else
                 echo -e "$UP$START $RED*$NORMAL$END[${RED}fail${NORMAL}]"
             fi
    I'm not at all sure this belongs in "Ubuntu Screenshots / Art Talk", but I figured it was about making Ubuntu pretty, and I didn't know where else to put it.

  2. #2
    Join Date
    Oct 2004
    Location
    Lancaster, Pennsylvania
    Beans
    147

    Re: Green [ ok ] messages

    Quote Originally Posted by rasher
    I was annoyed that during boot, only the status messages showing [fail] got coloured (red), so I created a very simple patch that makes the [ ok ] messages appear in green.

    The patch applies to /lib/lsb/init-functions

    Code:
    --- init-functions.orig 2004-12-18 23:45:08.756780424 +0100
    +++ init-functions      2004-12-18 23:44:52.699221544 +0100
    @@ -190,9 +190,10 @@
             END=`$TPUT hpa $COL`
             START=`$TPUT hpa 0`
             RED=`$TPUT setaf 1`
    +       GREEN=`$TPUT setaf 2`
             NORMAL=`$TPUT op`
             if [ $1 -eq 0 ]; then
    -            echo "$UP$END[ ok ]"
    +            echo "$UP$END[ ${GREEN}ok${NORMAL} ]"
             else
                 echo -e "$UP$START $RED*$NORMAL$END[${RED}fail${NORMAL}]"
             fi
    I'm not at all sure this belongs in "Ubuntu Screenshots / Art Talk", but I figured it was about making Ubuntu pretty, and I didn't know where else to put it.

    I know what you're talking about, and how to apply it, but howabout explaining how to apply the patch for those that don't know.
    "For to me, to live is Christ and to die is gain." - Philippians 1:21 (NIV)

  3. #3
    Join Date
    Dec 2004
    Location
    Piacenza - ITALY
    Beans
    23

    Re: Green [ ok ] messages

    I think he would like to say to remove lines that starts with -, and add lines that starts with +.

    Iive not already tried.

    Good tip.
    TNX
    Live from Piacenza (ITALY)

  4. #4
    Join Date
    Nov 2004
    Location
    NJ
    Beans
    216
    Distro
    Ubuntu Karmic Koala (testing)

    Re: Green [ ok ] messages

    oops, i didnt take out the minuses but it still works.

  5. #5
    Join Date
    Oct 2004
    Beans
    369
    Distro
    Gutsy Gibbon Testing

    Re: Green [ ok ] messages

    This patch should be default in ubuntu.

  6. #6
    Join Date
    Jan 2005
    Beans
    8

    Re: Green [ ok ] messages

    What are other possible colors to use?

  7. #7
    Join Date
    Dec 2004
    Location
    Austria
    Beans
    61
    Distro
    Ubuntu 10.10 Maverick Meerkat

    Re: Green [ ok ] messages

    Quote Originally Posted by fng
    This patch should be default in ubuntu.
    Yeah, I was thinking exactly the same thing right after booting Ubuntu for the first time. Thanks rusher

  8. #8
    Join Date
    Oct 2004
    Beans
    31

    Re: Green [ ok ] messages

    Quote Originally Posted by fng
    This patch should be default in ubuntu.
    yes another distros have it

    but uslpash will hide this patch

  9. #9
    Join Date
    Dec 2004
    Location
    Egypt
    Beans
    14

    Re: Green [ ok ] messages

    Yeah thanks , as i have been used to seeing the OK green

    it gives me a good feeling that everything is working right

  10. #10
    Join Date
    Jan 2005
    Location
    Moscow
    Beans
    5

    Re: Green [ ok ] messages

    Quote Originally Posted by oddabe19
    I know what you're talking about, and how to apply it, but howabout explaining how to apply the patch for those that don't know.
    patch -p0 < /path/to/this/patch

Page 1 of 3 123 LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •