Saurabh Verma
Saurabh Verma

Reputation: 6728

Simulating pressing of 'Page up' key in a shell script

Is there any way by which we can simulate the pressing of 'Home' and 'Page up' key in shell script ? i.e. Running that script should have/cause the same effect which is caused by pressing 'Page Up' key

Upvotes: 0

Views: 517

Answers (1)

ninjalj
ninjalj

Reputation: 43688

Previous page: tput kpp, Home: tput home.

Now, you'll need to send these to the program you're trying to interact with. expect is quite useful for this.

Upvotes: 2

Related Questions