Hi,
It is the tab positions in the ruler.
Regards
Dave
Dave,
I'd appreciate if you can explain it in detail. I am not a vim/vi editor expert but I know good enough to get my stuff done, so if you can provide me with a short description on what you mean the "tab positions in the ruler" it will be helpful.
I agree that link will not give the complete solution to the user but if user can go through the link properly he will find many options related to vi and it may clear user's some of the queries too. I am Sorry if I have broken a forum rule here.
Thanks,
R. Singh
Hi Ravinder.. Yes but the information that the OP is looking for cannot be found on that page. That is one of the reasons why it is good practise to quote the part on a page that answers the OP's question as well as provide a link. This practise also forces you to verify / double check if the information can be found and if not come up with a better link..
This User Gave Thanks to Scrutinizer For This Post:
Thanks Bakunin, here is the information you have asked for:
system: uname -a
Linux x86_64 x86_64 x86_64 GNU/Linux
From: less /etc/redhat\-release
Red Hat Enterprise Linux Server release 5.6 (Tikanga)
VI version:
vi --version
VIM - Vi IMproved 7.0 (2006 May 7, compiled Aug 4 2010 07:21:08)
which vi --> vi=vim ---------- Post updated at 11:31 AM ---------- Previous update was at 11:11 AM ----------
Thanks for the link Dave, but I was still not able to find the exactly what it denotes. The link concentrates on how to enable the line number, which in my case is already on.
By exploring a little more it
line 12
4 is indicating the 4 character need to know what 8 is
a sample record from my file:
the above [4-8] comes when my cursur is right in front of '*050' when i move the cursor over on to 0 it will become [5-9] and when move it over on 5 it will become [6-10] so on an so forth.
hope this helps to understand what it is, its definitely not the width of the column.
In your examples, 12,4-8 means that the cursor is sitting on line 12, the first byte of the character under the cursor is the 4th byte of the line, and the last column position occupied by that character is 8. The 1st three bytes on that line each contain the one byte character "9" and the character under the cursor is the one byte character <tab>. When you move the cursor to cover the "5", that character is the 6th byte on that line and is displayed in column 10.
For another example (using multi-byte characters), if you're using UTF-8 as your code set, if you have a file containing the line:
which when viewed using od -bcis:
when the cursor is over the "a", you'll see 1,1-1; when the cursor is over the "â", you'll see 1,2-2; when the cursor is over the "Â", you'll see 1,4-3; and when the cursor is over the "1", you'll see 1,6-4.
This User Gave Thanks to Don Cragun For This Post:
Hi Folks,
I have opened a log file through Vi editor in putty itself and I was searching for a pattern in logs , let say 'ABCD'
/abcd
then I want to come out from vi editor, Please advise what is the command to come out from unix editor..! (1 Reply)
Hi! I'm trying to assign line numbers to each line of the file
for example consider the following..
The contents of the input file are
hello how are you?
I'm fine.
How about you?
I'm trying to get the following output..
1 hello how are you?
2 I'm fine.
3 How about you? ... (8 Replies)
I know if i use grep -n that the output will have the lines numbered but is there a way to grep the actually line number.
so like this
grep -n "one" /usr/dict/numbers
1:one
21:twenty-one
31:thirty-one
41:forty-one
51:fifty-one
61:sixty-one
71:seventy-one
81:eighty-one
91:ninety-one
... (1 Reply)
hi there ,
i m new to unix , i d like to ask how can a get only even numbered lines matches with the word i search from txt file
for example :
3461:1.D. The copyright laws of the place where you are located also govern
3471:1.E. Unless you have removed all references to Project... (17 Replies)
Hi all,
I have a file consisting of lines in such a format: separated by space and M1 EOS for fullstop (.) ]
e.g
M1 I
M1 have
M1 a
M1 file
M1 consisting
M1 of
M1 lines
M1 in
M1 such
M1 a
M1 format
M1 EOS
M2 This
M2 is
M3 an (4 Replies)
Hi i would like to add line numbers to end of each line in a file.
I am able to do it in the front of each line using sed, but not able to add at the end of the file.
Can anyone suggest
The following code adds line number to start of each line
sed = filename | sed 'N;s/\n/\t/'
how can i... (5 Replies)
Hello..
I have got one file ...
I want to add line numbers with space form starting to ending..
for example...if the file is
--------------------------
sand sorcd 2345 345
recds 234 234 5687
yeres 568 988 erfg4 67
--------------------------
I need the output
... (4 Replies)
Maybe this question is out there, but I searched and didnt see it.
To print my files I use
more filename | lpr -Pprinter
I would like to print my scripts with line numbers.
How do I do this? (2 Replies)