fgconsole(1) on Linux
The text 6ce41ed1afbb, as Debian 10 (Buster) shipped it.
print the number of the active VT.
Flags it lists
-
--help -
--next-available -
--version -
-V -
-h