A terminal is a hardware device used for entering data into and displaying information from a computer. Terminals were frequently used in the days of mainframe computers. Today, most operating systems offer text-based "terminal emulators", which replicate the functionality of a classical terminal, ...

learn more… | top users | synonyms

10
votes
4answers
4k views

iTerm2 Vim alt+right/left arrow

As a Linux user, I am very used to jump from word to word in vim/nano using ALT+left or right. This doesn't seem to work properly using iTerm, I am using zsh, I tried adding; bindkey -e bindkey '^[[...
10
votes
3answers
10k views

How to display unicode in a Linux virtual terminal?

Reading any data in unicode does not display correctly in the linux terminal (meaning the virtual terminal that opens without an X windows). I read in a discussion here that installing programs such ...
9
votes
3answers
36k views

Close SSH connection

I'm using Mac's Terminal App and I know how to connect to an external server via ssh (ssh -l username domain.com). But how do I close the connection once I'm done? Thanks.
9
votes
3answers
8k views

How do I set my shell in Mac OS X?

I know I can set "Shells open with" in the Terminal preferences, but I'm curious if there's any system-wide way of setting this (similar to updating /etc/passwd in some Unixes).
9
votes
5answers
54k views

linux terminal undo rm 'somefile' [duplicate]

Possible Duplicate: undo Linux's rm? is it possible to undo a rm somefile command in linux? and if so, how does one do that?
9
votes
8answers
492 views

Is there a way to jump to an earlier part of a command line command in the Mac Terminal?

I'll often find myself writing out long commands in the bash shell - things with many arguments, web addresses, routes, etc and so on. Every so often I will realize I forgot to, say, put my "bundle ...
9
votes
4answers
7k views

Applescript to open a NEW terminal window in current space

Yes, I'm having a terrible newbie experience with Apple Script. I need to open a new Terminal window in the current desktop space. NOT move me to another space which has a Terminal running and then ...
9
votes
2answers
404 views

Take stdin from file but still have it show up in terminal

I have a program which requires me to input data as the program runs. Imagine it something like so: $ ./program Hi there. What's your name? Zambezi What is your quest? To make a program which runs ...
9
votes
2answers
5k views

How to close a tmux session

I am using tmux to manage multiple terminal windows. Currently I have 2 windows open with multiple panes. I know that I have to use the prefix (for me it is ctrl+a) to enter commands. How can I ...
9
votes
2answers
6k views

How to disable flashing terminal in Mac OS

when i enter terminals commands etc and hit TAB (file name completion) the whole terminal window flashes rapidly (if there is no unique filename for example). This is not good since for some people ...
9
votes
2answers
22k views

Trying to unzip a file, 'Filename not matched' when the directory exists

While trying to unzip a file named Joomla_3.0.3-Stable-Full_Package.zip to the directory named joomla I get filename not matched. Why is that? [root@Feddy Joomla]# unzip -Z Joomla_3.0.3-Stable-...
9
votes
3answers
44k views

How to reset Bash on Mac OSX, .bash_profile corrupted and bash no longer works

I am on a MacBook Pro, running the latest version of Mountain Lion. I really need some help, I have managed some how to damage my .bash_profile (I think) so that every time I open up the terminal I ...
9
votes
3answers
28k views

Ctrl+Alt+T doesn't open a Terminal in Cinnamon 1.6

I just updated to the stable version of Cinnamon 1.6 in Ubuntu 12.04 x64, but I found a bug which just get's me out of my skin. The key combination CtrlAltT which is supposed to open up the Terminal ...
9
votes
3answers
2k views

Unable to launch application in tmux

I get this error when I try to launch Sublime Text or SourceTree from tmux: $ subl Unable to launch Sublime Text 2 $ stree Unable to open SourceTree It seems that I can't open os x apps either: $ ...
9
votes
2answers
14k views

How to create a file and insert a line in it using OS X terminal

How can I do the following using the terminal on OS X? Create a file named .inputrc in a user's home directory and put this line in it: set completion-ignore-case On
9
votes
5answers
3k views

How to check if cygwin mintty/bash is run as administrator?

Problem Statement: What is the most elegant and robust way to test if Cygwin mintty bash session is "Run as adminstrator"? Why, specifically? I have typically several mintty terminals open when using ...
9
votes
5answers
4k views

Different Color for command and output

I was wondering if it is possible to change the color of the output of a command in linux to a different color than that of the command line where I type in. It is som monotonous and hard to find ...
9
votes
2answers
4k views

Removing files matching a numeric range regular expression

I have a folder which has many files. Some of the data files are labelled 1, 2, 3, ..., 300 I want to remove these data files using the terminal. How do I do this? I want to do something like rm ...
9
votes
2answers
19k views

Changing font size in Text Mode terminal

I have Ubuntu working in TEXT mode. I would like to change the font size (or if possible, get my terminal with inconsolata font). How can I do this? PS: I don't have a GUI or X Windows running.
9
votes
2answers
3k views

Pretty print folder structure using linux terminal?

How can you pretty print a directory structure with all subdirectories to the deepest level in the linux terminal(ubuntu)? This is an example of such a pretty print output for a mysite folder: mysite ...
9
votes
1answer
3k views

How to convert a date string to the current time zone on the command line?

How can I convert a date/time string, e.g. 2011-11-13 08:11:02 +0000, to my local time zone on the command line?
9
votes
2answers
7k views

Open terminal on start in a specific place and size

I want that each time I login to my account (Ubuntu-desktop) a Terminal will open in a specific location and in a specific size. In which file do I put the command, and what is the command?
9
votes
3answers
3k views

Switching tabs in Mac terminal with Ctrl+PageUp/PageDown

I've recently started using a Mac (running Lion), and there is one inconsistency that's getting to me. In Chrome and MVim, I can switch tabs with Ctrl+PageUp/PageDown. But, in the Terminal, I have ...
9
votes
2answers
15k views

How to login as a different user in terminal?

I'm currently logged in as a normal user in OS X. I'd like to start a terminal session and login as user foo. Is this possible?
9
votes
2answers
7k views

VIM: How to configure Solarized colorscheme in Konsole

I am trying to configure Solarized for use in VIM in Konsole (KDE terminal). This is the result that I get: Note that Solarized looks fine in GVIM on the same machine: I suspect that it is Konsole'...
9
votes
3answers
23k views

Increase linux terminal scrollback buffer size

I'm using CentOS 5.4 servers installed in a VMWare virtual machine with no X.Org server installed, so all access is via command line and the linux terminal. I use Shift-PgUp to view the scrollback ...
9
votes
1answer
393 views

How can you reverse the direction of alt-period in Bash?

In Bash, you can press Alt-. to insert the last argument of the previous command. If you press it multiple times, it cycles through the last arguments of all of the commands in your history. However, ...
9
votes
1answer
1k views

Mac OS X Lion Terminal SSH connection sharing error

I sometimes get this error when I try to ssh to a remote host: mux_client_request_session: read from master failed: Broken pipe I'm using Macbook Air OS X Lion with this in ~/.ssh/config: ...
9
votes
2answers
2k views

Fixed highlighting in tmux

I miss highlighting (reverse mode) on console since I started to use urxvt + tmux as main terminal. The highlights was replaced with with italic font - what looks pretty cool at first - however I can'...
9
votes
4answers
311 views

How to quickly get the previous line output in a terminal without using a mouse?

Linux (e.g. Ubuntu) terminal, is there a method to get the last line? Say I am randomly typing a td command, which has not been installed on my system, so I will get a message like below. I would like ...
9
votes
1answer
5k views

How to connect 2 Macs via SSH on a home network?

First off, I'm not 100% sure this question is on-topic on StackOverflow, but here you go : I've set up a home network : 1 wireless router connected to the internet my 2 Macs connected to the ...
9
votes
1answer
7k views

How to select text in BASH terminal using the keyboard without mouse?

How to select text in BASH terminal using the keyboard without mouse? I'm using Ubuntu 10.10
9
votes
1answer
14k views

Terminal inside sublime text

A long time ago when I used gedit, I was able to have a built in terminal at the bottom. This allowed me to sftp into my server, edit code, and then compile it in the terminal right inside the ...
8
votes
6answers
952 views

In Bash (Mac/Linux terminal shell), can the up and down arrow keys be made to function as they do in text editors?

In text editors, if I press the up and down arrow keys, it moves the cursor between lines of text. In Bash, if I’m typing a long command that spans multiple lines and I press the up and down arrow ...
8
votes
4answers
10k views

I just got a Mac! How do I do “end” , “home”, “page up” and “page down” in my terminal/VIM editor?

I write a lot of python in my VIM, on the terminal. What do I do?
8
votes
4answers
14k views

Installing a library locally in home directory, but program doesn't recognize it

I am installing a program on a server as a non-root user. Specifically it is tmux 1.5, but this should apply broadly to all locally installed program in my opinion (I mention the program name in case ...
8
votes
4answers
43k views

Mac Terminal SSH file transfer?

Is there a way to transfer files directly from a Mac to another using only Terminal? Perhaps using SSH?
8
votes
3answers
6k views

ChromeOS CLI terminal app?

I assume ChromeOS has a CLI terminal application. Does it open up in a browser tab, or is it an independent window? Does anyone have any screenshots handy?
8
votes
5answers
5k views

How can I partially clear my terminal scrollback?

I want to partially clear my terminal scrollback history, but only from where I have selected with my mouse in the scrollback and up. Is this possible? I'm on a Mac, and I use iTerm2 and Terminal.
8
votes
2answers
10k views

end-of-line, beginning-of-line keys for Terminal.app on Macbook Pro Keyboard

On a Macbook Pro keyboard, how do you go the the end-of-line and beginning-of-line in Terminal.app? Note that Ctrl-a and Ctrl-e on this computer with default configuration does not work. They just ...
8
votes
4answers
47k views

How do I recursively remove subdirectories and files, but not the first parent directory?

I'm able to use the following to remove the target directory and recursively all of its subdirectories and contents. find '/target/directory/' -type d -name '*' -print0 | xargs -0 rm -rf However, ...
8
votes
3answers
16k views

How to set up a shortcut to a directory in Mac OS X Terminal?

What I'd like to be able to do is when I'm in Terminal is to type: cd myFolderShortcut And for it to go straight to a directory I have a set up with this alias. Is this possible? I did do a google ...
8
votes
7answers
5k views

how to beep on tail -f event

I want my PC to make a system beep on every tail event I have the following command tail -f development.log | grep "something rare" is there an easy way like pipeing it to somthing that beeps? ...
8
votes
6answers
4k views

GNU Screen won't inherit my PATH on 10.5.8

I use screen on a daily basis for my terminal needs and I'm quite happy with it. Recently, though, I made some updates to my bash configuration files and I noticed that I was setting various PATH ...
8
votes
4answers
11k views

How to execute a shell script with selected files/folders in finder?

I'm coming from Linux where it's easy to run a script against a set of files in nautilus or dolphin, but I was kind of surprised to see that this isn't easy in OSX. Preferably, I would love to be ...
8
votes
3answers
32k views

color coding mac terminal

how do i get the mac terminal to display colors? i.e. in fedora when i use ls it color codes the results based on if it's a file or folder. similar results on mac?
8
votes
3answers
165 views

How to have a better view when typing out directories in terminal?

I am currently using a Mac and learning to use the terminal, but the question applies to Linux systems as well. I would like to ask, when typing out paths in the terminal/command line, is there a way ...
8
votes
5answers
5k views

Cygwin Terminal backspace and arrow keys not working

The arrow keys returns A,B,C,D and my backspace key are not working properly . This problem happens only with the vi editor.Is there any way to solve this issue on Cygwin ? I did find possible ...
8
votes
4answers
24k views

On Mac, how do I give myself permanent sudo privleges?

In Mac OS X 10.6, how do I give myself permanent sudo privleges? is it like linux, in the "/etc/sudoers" file?
8
votes
3answers
6k views

Lightning bolt for prompt (PS1)

I've seen on a few screencasts a while back where someone had a lightning bolt instead of $ on the bash prompt. Does anyone know how to do this?