Hot Keys


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Hot Keys
# 1  
Old 12-06-2006
Hot Keys

I am a new user, using Unix in a DOS window. Can I set up Hot Keys to run a script? Example - A12.1.13.15 aaaaBbbbCccc
Thank you,
cwtlr
# 2  
Old 12-06-2006
What do you mean by using UNIX in a DOS window? Are you connecting to a shell with ssh or something like that?

I'm not sure I understand your example. You want to type in A12.1.13.15 and have it come out as aaaaBbbbCccc? Try
Code:
$ alias A12.1.13.15="echo 'Hello there'"
$ A12.1.13.15
Hello there
$

# 3  
Old 12-08-2006
hot key

Thanks for your reply.
Many of the commands I use are preceeded with the same series of letter/number combinations. For example "P14.1.166.444 AaaaBbbbCccc". I'm looking for a hot key that I can replace that long letter/number preceeder with.
cwtlr
# 4  
Old 12-08-2006
Again, alias can do what you want.
Code:
$ alias abc="P14.1.166.444"
$ abc ...

# 5  
Old 12-08-2006
If you're looking for special key combinations to do that, that's not going to be in the shell, that'd be configured in whatever client program you use to connnect -- your "DOS window", which I'm assuming is actually an SSH window to UNIX. A DOS window would have DOS.
# 6  
Old 12-13-2006
hot key

Thanks for the advise. I guess I don't understand how to use the alias. I'm in the Command Prompt window. I type alias, then a space, then the letter combination that I want to replace my long string with (example - pri=), then the string that I'm replacing, enter. After that, when I type pri it is the same thing as typing the long string that I was using. This doesn't work. Is there a space or other key I'm missing, or did I mis-understand your instruction?
Thanks.
cwtlr
# 7  
Old 12-13-2006
Hi Dude!!!!!

Before doing that just check which shell r u using.
Alias command differs from shell to shell.
For Info check the man page.

man alias

Cheers
kishor
Login or Register to Ask a Question

Previous Thread | Next Thread

4 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

What are public keys in ssh and how do we create the public keys??

Hi All, I am having knowledge on some basics of ssh and wanted to know what are the public keys and how can we create and implement it in connecting server. Please provide the information for the above, it would be helpful for me. Thanks, Ravindra (1 Reply)
Discussion started by: ravi3cha
1 Replies

2. What is on Your Mind?

Too Hot Here

Officially, we had high of 96°F with a relative humidity of 52% here in Rockville Md today. But my car's thermometer said the outside temp was 110° when I first got in this afternoon. After driving for 30 minutes it cooled down to 103°. I actually have a nasty burn on my hand just from leaning... (19 Replies)
Discussion started by: Perderabo
19 Replies

3. UNIX for Dummies Questions & Answers

Hot Keys

I am a new user, using UNIX in a DOS window. Is there a way to code a "Hot Key" for a string of commands? Thanks. (2 Replies)
Discussion started by: cwtlr
2 Replies

4. UNIX for Dummies Questions & Answers

arrow keys / special keys

how to use the arrow keys in shell scripting. is there any special synatax / command for this. i just want to use the arrow keys for navigation. replies appreciated raguram R (3 Replies)
Discussion started by: raguramtgr
3 Replies
Login or Register to Ask a Question