Operating System - HP-UX
1833934 Members
1776 Online
110063 Solutions
New Discussion

ESC vs TAB (POSIX vs BASH)

 
Jorge Fabregas
Regular Advisor

ESC vs TAB (POSIX vs BASH)

Hello everyone,

I'm constantly working against Linux and HP-UX servers. I use a lot the shell autocomplete (filename expansion) feature (on both OS's).

I find myself pressing the TAB key on HP-UX (thinking I'm on a Linux machine -unconscious) or the other way (pressing ESC ESC on a Linux machine). I would like to standardize this.

Is there a way I can change the "ESC ESC" pattern on HP-UX to make it a TAB (like in Linux?). Is there something like "stty autocomplete TAB"??? hehe

Any suggestions?

Thanks,
Jorge
4 REPLIES 4
Stefan Farrelly
Honored Contributor

Re: ESC vs TAB (POSIX vs BASH)

I believe you can download and install bash for hp-ux!

http://hpux.cs.utah.edu/hppd/hpux/Shells/bash-2.05b/

Im from Palmerston North, New Zealand, but somehow ended up in London...
Jorge Fabregas
Regular Advisor

Re: ESC vs TAB (POSIX vs BASH)


Hello,

I'm sorry. I didn't specify that fact. I still want to use POSIX. I just would like to change the character key used for the autocomplete feature.

Thanks,
Jorge
Steven E. Protter
Exalted Contributor

Re: ESC vs TAB (POSIX vs BASH)

Jorge,

I asked this vary same suggestion to one of HP's Linux experts in California in 2002. She advised me that it was bettter to not take these steps, because of the following reasons:

1) Standardization: If someone else comes into your shop while your'e on vacation or education or whatever, it will make life difficult for them. Linux people expect tab tab auto complete and HP-UX people expect esc esc. I work with both systems and after three years have finally cut my mistake rate down to a reasonable level.

2) Re-arranging these functions will affect other functions that we like about the Linux/Posix shell, depending on which you mess with.

That being said, stty -a you can play to your hearts content with the keystroke sequences and try to achieve your goal.

Good Luck,

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Umapathy S
Honored Contributor

Re: ESC vs TAB (POSIX vs BASH)

Jorge,
ESC ESC pattern can be achieved in bash using set -o emacs. But emacs editing will come into picture and you wont be able to ESC-k for previous comamnds.
Otherwise, as Stefan suggested, install bash for hpux.

HTH,
Umapathy
Arise Awake and Stop NOT till the goal is Reached!