Screenshot tools for the command line
Say Cheese
Linux is awash in desktop screenshot tools, but what if you want to take a quick screenshot from a terminal window?
Suppose you want to record the contents of a computer screen or window. Linux is blessed with a number of useful tools that capture the view on your screen at a given moment. You can use screenshots to preserve critical information, document the contents of web forms, or illustrate application procedures. Most of the popular screenshot tools, however, are desktop applications. What if you don't want to slow down and maneuver through a GUI just to capture the contents of your screen? Many users don't realize you can also create screenshots from the command line. Command-line screenshots are a quick and useful option when you are working in a terminal window, and conjuring up a screenshot through a one-line command means you can add screenshots to your Bash scripts. In this article, I'll show you three powerful screenshot utilities available in the Ubuntu 22.04 Linux command-line interface (CLI): scrot
, gnome-screenshot
, and import
.
scrot
SCReen shOT (scrot
) is a lightweight and simple command-line tool for capturing screenshots in Linux [1]. It offers a range of options and is highly configurable. To install scrot
on an Ubuntu 22.04 system (Figure 1), enter:
$ sudo apt install scrot
[...]
Buy this article as PDF
(incl. VAT)