2
votes
1answer
49 views

Incremental history searching

I found this very useful tip in UsingTheTerminal to use the arrow keys to search through the command history: "\e[A": history-search-backward "\e[B": history-search-forward "\e[C": forward-char ...
0
votes
1answer
35 views

How do I enable automatic history expansion for commands using 'magic space'?

I read on a blog somewhere about the possibility to use automatic history expansion before actually executing a command or even pressing the enter key in the command line. It involves the ...
1
vote
0answers
38 views

How to find the directory on which a particular command is executed? [duplicate]

I already installed nautilus-open-terminal package. So i can openup terminal from any directory. Like that i opened a terminal from a directory(i forgot it's path) and executed apt-get download vlc ...
13
votes
4answers
602 views

Run last command with all the letters transformed to lowercase

Many times I have run a command with all the letters in uppercase (maybe because CapsLock was on), and I pressed Enter before realising this. How can I run the last command with all the letters ...
1
vote
1answer
79 views

List all manually installed packages similar to history.log file

I searched the whole internet for this but did not find any satisfactory answer for this question. aptitude search ‘~i !~M’ | less does not show the manually installed packages. On my system it ...
1
vote
0answers
71 views

Display list of most used commands [duplicate]

The command history will display the list of commands I used before. Now: How could I know the most used commands? Also how to count number of times I used each command? For example: If I use ...
1
vote
1answer
901 views

Save the terminal history to a file for print

My Ubuntu headless server is about to lose both hard drives(raid1). I already saved the most important stuff. Now I'm sitting in front of a Mac OS X client with the terminal open (ssh). I need to ...
1
vote
2answers
155 views

Prevent user from executing history -c command in shell

Is it possible to prevent specific user from executing history -c command in shell.
12
votes
3answers
6k views

How to view the `.bash_history` file via command line?

I want to view the contents of my .bash_history file but don't know how to get there via the command line.
0
votes
1answer
172 views

How can I enable history completion by program in terminator as guake has it?

In guake I can type ls UP-ARROW and it will show ls /home/blah for example. In terminator using up arrow after typing ls just brings me to the command I entered prior. Is there any way to enable this ...
6
votes
2answers
96 views

Using last part of command for next command

When using the command I know a friend of mine who used to re-use last part of previous command. He unfortunately moved far away and I can't get hold of him. First: cp -r folder ~/folder Then he ...
6
votes
1answer
1k views

Is there a centralized history file for all the commands run from various terminals?

I am aware that every terminal has it's separate history,which can be viewed by the history command. Commands issued on suppose terminal tty1 will be shown in the history of tty1 only and not in the ...
3
votes
2answers
1k views

Install history command package

I have Ubuntu 10.04.4 LTS running on a proxmox OpenVZ container. I imagine it does not come with history because the up arrow on the command line gives me ^[[A plus... $ history -sh: history: not ...
0
votes
2answers
546 views

clean history script not working

I'm creating a script to run in the start up that says: _cleanthehistory () { /bin/echo "cleaning the history" history -c } _cleanthehistory The deal here is that this does not work from the ...
2
votes
0answers
365 views

How can I make the LXTerminal accept the arrow key for history search? [closed]

In the bash, one can enable a "search-as-you-type-like" behaviour by changing eg. the .inputrc : 1 ## arrow up 2 "\e[A":history-search-backward 3 ## arrow down 4 ...
2
votes
1answer
2k views

How can I set HISTSIZE for all users?

How can I set HISTSIZE for all users on Ubuntu 10.04? I've tried adding the following lines to both /etc/profile and /etc/bash.bashrc. I'm not sure I understand the difference between the two files ...
34
votes
3answers
14k views

Bash history search, partial + up-arrow

I have searched, but not found anything on this. I am looking for a functionality in bash, using a terminal. Way back when, I had a user on a debian system, and a friend set me up with a convenient ...
10
votes
4answers
6k views

Bash command history not working

The command history between sessions is not getting saved. I'm using guake and the history for the session is working fine. I noticed that .bash_history had some commands I executed in sudo -s mode ...
11
votes
1answer
5k views

How do you share history between terminals in zsh?

How can it be achieved so that every command that is entered, is visible in every open terminal's history? When having multiple terminals open, the history isn't shared, i.e. what you entered in one ...