Forrest logo
back to the tput tool

tput:tldr:7b944

tput: Move the cursor to a screen location.
$ tput cup ${row} ${column}
try on your machine

The command tput cup ${row} ${column} is used in the Linux terminal to move the cursor to a specific position on the screen. It uses the tput command to interact with the terminal's terminfo database, which contains information about the capabilities of the specific terminal being used.

The ${row} and ${column} are variables that represent the row and column numbers of the desired position on the screen. By providing the appropriate values for ${row} and ${column}, the cursor can be moved to that specific location.

For example, if you want to move the cursor to the top-left corner of the screen, you would use tput cup 0 0, where 0 represents the first row and column.

This command is commonly used in shell scripts or other programs to control the cursor's position and control the layout and placement of text or graphical elements on the terminal screen.

This explanation was created by an AI. In most cases those are correct. But please always be careful and never run a command you are not sure if it is safe.
back to the tput tool