0
votes
1answer
23 views

How to apply “set number” to vi on root?

I'm using vi on centos 6.5 and added "set number" script to /etc/bashrc in order to look line numbers whenever boot. It works well to show it on user login but not root. How to apply "set number" of ...
0
votes
1answer
23 views

What does “vi-move” keymap in Bash's vi mode actually do?

The keymap section in the Bash Reference Manual says that one of the acceptable options is "vi-move". There doesn't seem to be any description for what this corresponds to. I'm well acquainted with ...
0
votes
1answer
24 views

Replacing values in a file using vi

I have a file which as multiple entries like "allowed_users 100", "allowed_hits 100", "allowed_users 10000". Want to replace the values of "allowed_users 100" to "allowed_users 1000". Best Wishes, ...
0
votes
3answers
148 views

Unnecessary indenting in bash

I have been trying to paste text from one file to another in bash. I'm working in Putty. To be more clear, I have a file hotel.txt with some lines of text that are indented, thus have tabs and ...
1
vote
2answers
371 views

Increase the space between lines in vim

I think the title says it all. I've done my homework and the only command that I found was: :set linespace=3 but it doesn't seem to work, neither on the Mac nor in Linux. Edit: In Mac OSX you can ...
1
vote
1answer
100 views

Bash readline move cursor to previous forward slash

In bash , we can move back or forward by 1 word or character. Is there any option where i can move the cursor to the previous character that i specify, for example Forward Slash. ? Something like the ...
1
vote
0answers
346 views

bash vi key bindings: Can I map keys? Display mode (insert vs command)?

I am a long time vi(m) user and recently made the switch to using vi key binding in bash. I can already tell that this will be an improvement, but I would like to customize a few things to really ...
0
votes
1answer
385 views

Replace text with text from another file in a script?

I want to replace 5 rows of text in a file with the text of another file in my script, I know that running vim I can do :45,50d :r replacement.txt to delete 5 rows and then insert the entire file, ...
0
votes
1answer
459 views

Remap shift-tab to tab in bash/screen/putty in Linux?

Well I use vi-mode in bash via the set -o vi command. What's annoying is when I'm typing words in capital then try to complete using tab but don't release the shift-key fast enough, it brings me out ...
0
votes
0answers
318 views

Vim shell bindings (set -o vi) on iTerm2

Trouble with history when using bash vi bindings on iTerm2 on Lion. (I had the same problem with iTerm when I switched to Lion.) Hard to explain exactly, but when I hit k to go to most recent ...
0
votes
3answers
2k views

Ubuntu + Unable to Edit .bashrc file because of ReadOnly

I am getting the following warning: Unable to verify SSL certificate for api.heroku.com To disable SSL verification, run with HEROKU_SSL_VERIFY=disable By searching Google I was able to find a few ...
4
votes
6answers
6k views

UNIX - How to copy and paste between different bash windows with files opend with VI?

Lets say I log in to bash, open a file in vi, then using alt-f2 I open a new terminal. After logging in I navigate to a second file and open that in vi. How can I CnP between these two files? I found ...
3
votes
1answer
215 views

bash vi mode: what is (arg: N)?

I am using vi mode in a bash shell. If I enter insert command mode and type a number from 1-9 (eg: 5, in the example below), I get the following prompt: (arg: 5) <cursor> What does this ...
4
votes
1answer
2k views

How to pass vim buffer contents through shell command and capture the output to a split window

I've read lots of threads about running shell commands from vim, lots of documentation on vim commands, .vimrc and all that, but I just can't seem to understand the "ex" language or vim mappings well ...