Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 799
  • Last Modified:

How to enter CTRL+ L from a script

Hi there,

I want to enter "control key and L" from a script.  How can I do it?  Or have an alias for pressing "control + L".
CTRL+ L is clear screen in QNX.
0
ambuli
Asked:
ambuli
  • 2
  • 2
1 Solution
 
woolmilkporcCommented:
Don't you have "tput"?

Try

tput clear

Most Unixes have the "clear" command too. Simply:

clear

If you must use Ctrl-L  then you can do in vi:

Ctrl-V CTRL-L

wmp
0
 
ambuliAuthor Commented:
Thanks,
This is a strip down version of QNX and does not have many commands.

I want to do something like
alias clear = ????
0
 
woolmilkporcCommented:
Maybe this:

alias clear=`echo "\014"`

Please note the  backticks  `  `  !

Is there really no "tput"?


0
 
ambuliAuthor Commented:
Thank you. Ctrl-V CTRL-L  worked.
0

Featured Post

NEW Veeam Agent for Microsoft Windows

Backup and recover physical and cloud-based servers and workstations, as well as endpoint devices that belong to remote users. Avoid downtime and data loss quickly and easily for Windows-based physical or public cloud-based workloads!

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now