Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [terminal-emulator]

The tag has no usage guidance.

56
votes
4answers
13k views

What are the responsibilities of each Pseudo-Terminal (PTY) component (software, master side, slave side)?

I am trying to figure out how a tty works1 (the work-flow and responsibilities of each elements). I have read several interesting articles about it, but there are still some blurry areas. This is ...
43
votes
8answers
87k views

How can I hook on to one terminal's output from another terminal?

I need to hook onto output of currently running terminal (tty1) from virtual terminal and capture it (running X server).
1
vote
1answer
566 views

What type of terminal to support if implementing a terminal emulator? [closed]

I have heard that VT100 is the de facto standard. Does it mean if I can just support VT100 and then my terminal can work for existing commandline applications without big problems? If not, how to make ...
21
votes
3answers
15k views

Checking how many colors my terminal emulator supports

Is there a reliable way to check how many colors my terminal emulator supports? If echo $TERM prints xterm, does that unequivocally tell me how many colors my terminal emulator supports? How could I ...
13
votes
6answers
7k views

Can I see images and watch movies inside the terminal emulator

Can I see images and watch movies inside the terminal emulator? In case of virtual console I can do it via framebuffer, but what about terminal emulators?
5
votes
2answers
168 views

Process killed before being launched in background

I'm using a bash script script.sh containing a command cmd, launched in background: #!/bin/bash … cmd & … If I open a terminal emulator and run script.sh, cmd is properly executed in background, ...
2
votes
2answers
721 views

Why do multiple instances of Mate-terminal have the same PID?

I've noticed, that all mate-terminal instances I start, be it inside a mate-terminal or via a link button, have the same PID. For example, I got something like $ wmctrl -lp <omitted lines that ...
2
votes
3answers
1k views

How to determine the character encoding that a terminal uses in a C/C++ program?

I've noticed that SyncTERM uses a different character encoding than the default MacOS terminal emulator, and they're incompatible with one another. For example, say you want to print a block ...
24
votes
3answers
5k views

How can we know who's at the other end of a pseudo-terminal device?

If I do a: echo foo > /dev/pts/12 Some process will read that foo\n from its file descriptor to the master side. Is there a way to find out what that(those) process(es) is(are)? Or in other ...
14
votes
2answers
957 views

What is the most portable method of launching a terminal emulator?

Say I need to write a script that will launch a terminal and execute a command and I need that to work on various systems. How can I do that in a safe and portable manner? Is xterm always installed? ...
3
votes
1answer
1k views

Bind C-i and TAB keys to different commands in terminal applications via .inputrc

For what I have tried, TAB and C-i in .inputrc seems to mean the same thing, whatever I bind to one is bound to the other. I know that originally, it was the same thing and that this behavior is kind ...
0
votes
1answer
2k views

How to set the background color of the Linux console screen?

Note: I reworked the question to clarify the issues. This is a trivial question that can be answered in several parts because the question has several attributes. Unfortunately, the question may be ...
5
votes
1answer
1k views

Why are these fancy characters not shown in my prompt?

I am using Ubuntu 14.04 and 16.04. On 14.04 I additionally installed Terminology. On 16.04 Terminal and Terminology the characters in the bash are not displayed correctly: Look with Ubuntu 14.04 ...
31
votes
2answers
14k views

How does a Linux terminal work?

If you fire up a terminal and call an executable (assuming one that's line oriented for simplicity) you get a reply to the command from the executable. How does this get printed to you (the user)? ...
56
votes
4answers
29k views

Use Mosh without giving up local scrollback / history?

Is there a way to use mosh without giving up the local scrollback? Basically, in some circumstances, IP-roaming is indeed useful and needed, but the extra terminal emulation and key prediction seems ...
29
votes
2answers
6k views

How to avoid escape sequence attacks in terminals?

Reading the details of CVE-2009-4487 (which is about the danger of escape sequences in log files) I am a bit surprised. To quote CVE-2009-4487: nginx 0.7.64 writes data to a log file without ...
26
votes
3answers
18k views

What is making my cursor 'randomly' disappear when using gnome-teminal?

It happens often that my cursor on gnome-terminal disappears, forcing me to work on a new tab/window. It seems like a random occurrence. Does anyone else experience this? What about other X terminal ...
3
votes
2answers
3k views

How to disable mouse support in terminal?

I'm asking this question while using xfce4-terminal, but I'm interested in a general solution: is there a way to stop a terminal emulator announcing mouse support in consoles? I need mouse-select and ...
1
vote
2answers
97 views

What is the server-client relationship between a terminal emulator, a window manager and a X server processes?

In APUE (see the figure below), how do a terminal emulator process and a window manager (e.g. openbox) process communicate? Is a temrinal emulator process a client of a window manager process, based ...
7
votes
4answers
9k views

HTML client for X11 ssh forwarding?

Not totally sure if this is the right place but here goes. I understand that you are able to use X11 to ssh to GUI's and view them, without the server having a full on GUI system running/installed ...
6
votes
1answer
5k views

In Bash, why is PROMPT_COMMAND set to something invisible?

On RHEL6 and CentOS 6, /etc/bashrc sets PROMPT_COMMAND here: case $TERM in xterm*) if [ -e /etc/sysconfig/bash-prompt-xterm ]; then PROMPT_COMMAND=/etc/sysconfig/bash-prompt-xterm ...
7
votes
2answers
3k views

Can't apply brightness to terminal's background color

I have a problem with colors in my terminal emulator. I am using LXTerminal as my terminal emulator and LXDE as my desktop environment. The following command is supposed to print red text on grey ...
6
votes
1answer
4k views

Print true color (24-bit) test pattern

How can I test that my terminal / tmux is correctly setup to display truecolor / 24-bit color / 16.8 million colours?
3
votes
1answer
121 views

Is a virtual console running as a process and implemented based on pseudoterminal?

Linux has 7 virtual consoles, which correspond to 7 device files /dev/tty[n]. Is a virtual console running as a process, just like a terminal emulator? (I am not sure. It seems a virtual console is ...
2
votes
1answer
79 views

Is there an idiomatic variable for the terminal executable in Linux?

There's already EDITOR, BROWSER and VISUAL which point to various executables (with or without full path). TERM contains information about the type of terminal, not necessarily the name of the ...
2
votes
4answers
6k views

How to hold terminal open (excepting gnome-terminal)?

I find useful the gnome-terminal feature of editing (and creating) profiles with the option of holding the terminal open after the command exists. (I like to use context menu file manager to run ...
1
vote
3answers
130 views

Why does closing terminal emulator window terminate a bash process with SIGHUP trap changed not to terminate?

In a bash shell in a terminal emulator window of lxterminal, I run $ trap "echo hello" SIGHUP $ kill -s HUP $$ hello $ and then I close the terminal emulator window. Does closing the terminal ...
1
vote
2answers
4k views

Use a different shell by default in each terminal emulator

I would like to change the default shell in each terminal emulator separately. To clarify, I want xterm to use tcsh, pterm to use pysh, gnome-terminal to use bash, etc. Is this possible? If so, how ...
0
votes
2answers
1k views

How are long command lines ( > $COLUMNS ) automatically wrapped to a new line?

There are several points where I/O is passed through, some of which (to my knowledge) are the shell, pty, tty, termios, terminal emulator application. In most terminal emulators, long command lines (...
0
votes
1answer
125 views

Where is terminal output stored?

I open lxterminal, which shows up in ps output as x-terminal-emulator. I then enter a command which prints it's output to STDOUT, which is visible on my screen. The command finishes, and I am shown ...
48
votes
3answers
74k views

Which terminal type am I using?

I have tested this with both Ubuntu 12.04 and Debian 7. When I do echo $TERM I get xterm But if I use the dropdown menu "help" > "about" then it says gnome terminal 3.4.1.1. Does this mean I am ...
31
votes
4answers
51k views

How can I set the position that terminal opens at?

I'd like Terminal to open near the bottom of my screen. Is there a way to set the default size and position? I'm using Linux Mint 13, Cinnamon.
11
votes
4answers
2k views

Are there any linux terminals which can handle all key combinations?

I like to use emacs in terminal mode (-nw), but it seems most (all?) terminals can't handle some key combinations - for example, C-<RET> or C-M-%. I know this is because most terminals emulate a ...
21
votes
6answers
3k views

Is there a terminal app that allows filenames to be clickable?

Is there a terminal emulator (extension or app) that does link resolution for local paths? In particular when I see things like: /home/sam/.gem/ruby/1.8/gems/actionpack-2.3.2/lib/action_controller/...
10
votes
2answers
55k views

Changing terminal emulators

I have ssh access to a remote machine. In this machine if I run echo $TERM I get xterm. If I want to change my terminal emulator to some other emulator (assuming that it's installed on the remote ...
12
votes
1answer
4k views

Scroll to the last command on Terminal? (like OS X Terminal marks)

Mac OS X Terminal marks are incredibly useful. For example, when I type a command that echoes a lot output, it's easy to read the beginning with Cmd+Up. It will scroll to the last command and ...
10
votes
1answer
2k views

prevent multi-line paste in bash

I often use ctrl+c to copy text from some gui application and then paste it into my terminal emulator (terminator), using right-mouse-click-menu and paste. Sometimes I forget that the clipboard ...
4
votes
2answers
2k views

Launching a terminal emulator without knowing which ones are installed

I need to write a script that will launch a terminal emulator and run a particular command in it. Since I don't know which terminal emulators have been installed on the target system, how could I find ...
8
votes
3answers
1k views

Are there terminal emulators that support bi-directional text?

I tried searching for this but came out empty-handed. Is it possible for me to get my terminal emulator to display right-to-left Unicode grapheme clusters properly? Use case: I'm writing a script ...
5
votes
6answers
5k views

Is there a (light-weight) replacement for `rxvt-unicode`?

I am currently using rxvt-unicode as a terminal emulator. Since I also like the configurability of terminal emulators from GNOME and KDE, I wonder whether there is some kind of replacement for rxvt-...
3
votes
1answer
1k views

Control pseudo-terminal (/dev/pts/*) assignments

Is there any way to control which pseudo-terminal (/dev/pts/*) a connection is given? For example, I have multiple thin clients each running individual terminal sessions to a RHEL server over SSH, I ...
3
votes
1answer
127 views

Why does Linux allow backspaces when pasting text into a shell?

In many Linux distributions I come across, backspace characters are included when pasting text into a shell. Why is pasting of these characters not prevented – or does this feature provide some useful ...
2
votes
4answers
3k views

Are there any terminal emulators with “true color” support available for Debian 8.5?

I've seen this gist and tried a number of options, but it seems, that the versions of those terminals in stable repository are too old and I need to compile newest from source and drag newer ...
6
votes
4answers
13k views

Can I change terminal type used to login through SSH?

When I login on some particular server through SSH (which I do not have admin access to), I get the following error: urxvt-unicode: Unknown terminal type (I also don't want to change my terminal type ...
4
votes
4answers
5k views

Solarized colors in st (simple terminal)

I want to use st with solarized colors like I can with urxvt (of course this is done via .Xresources, in st the colors are defined in a header file). I've tried to put the colors in st's config file (...
2
votes
2answers
929 views

Get the terminal emulator name inside the shell script

I have used pstree to find the name of the parent emulator of running shell script using something similar to the following: pstree -s $PPID | awk -F '---' '{print $6}' This works in my current ...
1
vote
1answer
59 views

Why is my terminal emulator process is using d-bus?

$ sudo lsof +E -a -U -p 1480 lsof: WARNING: can't stat() fuse.gvfsd-fuse file system /run/user/1000/gvfs Output information may be incomplete. lsof: WARNING: can't stat() fuse.gvfsd-fuse file ...
1
vote
0answers
862 views

logname: no login name

I am trying to understand the differences between logname and LOGNAME from Difference between logname and $LOGNAME and https://askubuntu.com/questions/490620/difference-between-logname-and-logname On ...
0
votes
2answers
474 views

To what extent are the xterm, xterm-color, and linux terminal emulators based on VT100?

My understanding is that all of these terminal emulators derive the ASCII control code behaviors and ANSI escape sequences from the VT100 standard. I also understand that there is an ANSI standard ...
-1
votes
2answers
70 views

PC speaker beep and messy terminal font due to dd if=/dev/sda?

When running sudo dd if=/dev/sda the internal PC speaker makes sounds. Also all fonts, even the prompt and typing input has different characters such as "♡" or "•". If you need to know more, ...