blink / flash echo text in a menu


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting blink / flash echo text in a menu
# 1  
Old 08-16-2003
Question blink / flash echo text in a menu

I have a ksh script that is a login menu for my end users. I would like to have one line of the welcome message flash when there is a system notice about an impending outage.
The welcome message is a series of echo statements which prints a text file "msg of the day" with the status msg.
I tried repeating a sleep and clear command on the whole welcome message but it didnt work well and looked a bit dorky.
Any ideas?


clear
echo "**********************************************"
echo "* WELCOME "
echo "* User id : $USER"
if [ -f $MSG_OF_DAY -a -n "$1" ]; then
print_msgofday
fi
echo "*******************************************************************\n"
# 2  
Old 08-16-2003
The TERM variable should be pointing to a database of terminal characteristics and you should be able to use tput to query it. There are a lot of characteristics defined but I suggest that you stick to a basic few. In particular, I would use smso and rmso for this type of thing (the letters mean [start|remove] mode stand out). Not all terminals can blink or bold or underline text. But almost all have some way to make important text stand out and they should all have something useful in smso.

quick ksh example:

echo abc $(tput smso) def $(tput rmso) ghi
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Programming

Listing Option Menu Choices from Text File

Hello, I am starting up a tool and one of the initial steps is to select a site/location which is being read from a text file. Here is the text file contents: site1 site2 site3 Here is the code: #!/usr/bin/python from Tkinter import * (3 Replies)
Discussion started by: tattoostreet
3 Replies

2. Shell Programming and Scripting

Perl simple text menu with options

Hopefully I'm in the right place. Im new to the forums and linux! I'm looking to add a menu to my perl hangman game i have created. The menu will use user input for the desired option and then perform the operation indicated. I would like something along the lines of: Welcome to Hangman... (1 Reply)
Discussion started by: jahburmski
1 Replies

3. UNIX for Dummies Questions & Answers

How to bold, blink, italicise words using echo command?

Hello Everyone. I am trying to bold, blink, italicise words using echo command. As per the research I did, it says to use the following escape code to get the effects. #!/bin/bash clear echo -e "\033 However when I am compiling I am not getting the desired effect. Can anyone... (7 Replies)
Discussion started by: grc
7 Replies

4. Shell Programming and Scripting

Echo Variables and Text

I've been trying to get the syntax right so I can echo a $var and then text around it or after it. It either wont display text or $var or one overwrites the other at the beginning of the line. Trying to do something like this. var=1 echo $var"+1.1" #output expected 1+1.1 Its an older... (3 Replies)
Discussion started by: Grizzly
3 Replies

5. Shell Programming and Scripting

how to BLINK on terminal???

hello sir, I want to blink a given text on the screen. I tried using the following :- I also used :- But still I am unable to see the text in the blinking effect.Can you please tell me where did I go wrong? Can you please tell me any other ways of blinking !!!!! (3 Replies)
Discussion started by: nsharath
3 Replies

6. UNIX for Dummies Questions & Answers

Selectable numeric text menu from file possible?

Is there a way i can take 'lets say the etc/group file' and arange the group names into a selectable numeric menu eg; 1) root:0 2) other:1 3) bin:2 4) sys:3 ..... ..... ..... and so on then GROUP="group name of users selection" i have tried for over an hour searching on... (6 Replies)
Discussion started by: switchkill
6 Replies

7. Shell Programming and Scripting

blink a text/message in a ksh script

can anyone tell me how to bink a text in a ksh script for e,g file 1 #!/bin/ksh "this is my file" ----------------------------------------------- i want "this is my file" text to blink.thanks (9 Replies)
Discussion started by: ali560045
9 Replies

8. UNIX for Dummies Questions & Answers

blink message..

hi all.. i need to know, how i can put a message on motd file...when the user loggon and the server send a welcome message but blink message... thank you... (1 Reply)
Discussion started by: chanfle
1 Replies

9. UNIX for Dummies Questions & Answers

is it possible to echo 'some text' every 10 minutes on my screen

is it possible to echo 'some text' every 10 minutes on my screen continues , without cron. (1 Reply)
Discussion started by: vkandati
1 Replies

10. UNIX for Dummies Questions & Answers

Changing korn shell script text Menu colors?

Is it possible to change the color of text in a korn shell script Menu? I can change the color of session text through my telnet client but I want to be able to change color text in the Korn shell menu to highlight certain items. (6 Replies)
Discussion started by: darthur
6 Replies
Login or Register to Ask a Question