1829595 Members
1966 Online
109992 Solutions
New Discussion

Unable to type @

 
SOLVED
Go to solution
Venkatesh babu sira_1
Occasional Advisor

Unable to type @

All masters,
When i triy to type @ ,it will clears the entire line,if any one knows which environment setting it will greatly app.
HP 11i rp 2450,patches to latest.
If i type # it will clear one character.
Thanks
-VB
12 REPLIES 12
MANOJ SRIVASTAVA
Honored Contributor

Re: Unable to type @

Hi Venkatesh


to type @ type cntrl v + @ this will not take you to the start of the line .


Manoj Srivastava
A. Clay Stephenson
Acclaimed Contributor

Re: Unable to type @

It appears that your stty delete line (kill) has been set to '@'. To confirm this do a stty -a. To fix: stty kill '^X' - to set it to a Cntrl-X. You may want to put this in your .profile iff stdin is a terminal.
if [ -t 0 ]
then
stty kill '^X'
fi


Man stty for details.
If it ain't broke, I can fix that.
harry d brown jr
Honored Contributor

Re: Unable to type @

VB,

type in:

stty -a

and report back what kill and erase are set to.

live free or die
harry
Live Free or Die
John Poff
Honored Contributor

Re: Unable to type @

Hello,

Try typing:

stty sane

and see if that helps.

JP
melvyn burnard
Honored Contributor

Re: Unable to type @

you could try doing:
eval `ttytype -s`
NOTE the grave or back quote, not forward single quote!
This requests the terminal type and attempts to set up the correct comms settings for that tye of terminal.
Then do:
tset


Now see if it is ok. If not, you will have to check your stty settings, and in your login profile nmaje the appropriate changes to ensure they get set coorectly when logging in.
My house is the bank's, my money the wife's, But my opinions belong to me, not HP!
Venkatesh babu sira_1
Occasional Advisor

Re: Unable to type @


1)to type @ type cntrl v + @ this will not take you to the start of the line
I can't type like that ctl v+shift 2(for @)
I am using bash

stty -a gives

intr = DEL; quit = ^\; erase = ^H; kill = @

2)stty sane
does n't work(@ still clear line)

3)eval `ttytype -s`
tset also does not work ,but it set kill to ^j

same as above
One thing i am not able to type ctrl X

Thanks
-VB
Frank Slootweg
Honored Contributor

Re: Unable to type @

As Clay mentioned, you will have to type Ctrl-X as *two* characters:

stty kill '^X'

I.e.: single (forward) quote ('), carrot (^), X and a closing single(forward) quote (').

As far as I know, most HP setups (see for example the sample /usr/newconfig/.profile file) use Ctrl-U, i.e.:

stty kill '^U'

Deepak Extross
Honored Contributor

Re: Unable to type @

Try escaping the "@" with the "\" escape character. For example, insted of typing "abc@xyz.com", type "abc\@xyz.com"
harry d brown jr
Honored Contributor

Re: Unable to type @

VB,

You need to change intr and kill:

stty intr ^C
stty kill ^U

To get the

^C

hold the control key down (ctrl-v) and press

v

then (while still holding the control key down - ctrl-c) press

c

Then do the same for

^U

stty kill (CTRL)v(CTRL)u

live free or die
harry
Live Free or Die
Frank Slootweg
Honored Contributor

Re: Unable to type @

For stty(1), the 'difficult' "hold the control key down and press v then (while still holding the control key down) press ..." is not neccessary: stty(1) understands control characters as *two* 'normal', but escaped, characters, carrot (^) and the desired control character (for example U). From the stty(1) manual page:

> If c is preceded by an (escaped from the
> shell) circumflex (^), the value used is the
> corresponding control character (for example
> ^d represents Ctrl-d); ^? is interpreted as
> DEL and ^- is interpreted as undefined.

And the specific example:

> EXAMPLES
> The command:
>
> stty kill '^X' intr '^C'

Bill Hassell
Honored Contributor
Solution

Re: Unable to type @

The real problem is that you aren't getting stty run as part of your login procedures. Are you using a 'real' terminal such as an HP 700/9x with a serial cable, or are you using a terminal emulator on a PC? If the latter, are you using telnet to connect or are you using Xwindows? Xwindows (the CDE manager) defaults to ignoring all profile steps and therefore bypasses /etc/profile, /etc/csh.login, .profile, .kshrc, .cshrc, .bashrc, etc...

So if you are using a graphics environment, this is likely the case--you are inheriting the standard hard-copy (as in teletype) settings and these need to be overridden. The standard HP-UX .profile will handle this as you login (using the POSIX shell). You can test this by simply running this .profile in source mode:

$ . ./.profile

Note the isolated dot prior to .profile as this is the secret to making settings stick in the current shell. For other shells, add these lines to the default startup file:

/sbin/stty erase "^H" kill "^U" intr "^C" eof "^D" -parity ixoff
/sbin/stty susp \^Z dsusp \^Y

These will set the 'standard' control keys. Be sure to put these lines into your shell's standard startup profile *and* configure the shell to run this script. In CDE, .profile is *NOT* run by default, read the last lines in $HOME/.dtprofile and follow the advice. Be sure to test that your profile is actually getting read. Also make sure that your $TERM is getting set correctly in your profile:

eval $(/sbin/ttytype -s)


Bill Hassell, sysadmin
Venkatesh babu sira_1
Occasional Advisor

Re: Unable to type @

Thanks folks it works now ,u r all great.
-VB