RE: Small fix for syntax/cfg.vim

2012-08-09 Thread John Beckett
Antony Lee wrote: I believe that the default syntax file for cfg files (syntax/cfg.vim) should be modified as follows: ... How should I submit this request officially? The procedure is to email the name shown in the file and wait a couple of weeks to see if there is a reply. Ideally, the

RE: Windows : autocmd fires up on right-click edit with vim, not on double click

2012-08-03 Thread John Beckett
Paddy wrote: I'm having an issue running Vim 7.3 on my Windows 7 workstation. I'm using it partly for editing todo files, for which I created a simple custom syntax file. I use the following command to use my syntax file on *.todo files, in my vimrc : $ au BufNewFile,BufRead *.todo set

RE: How to turn off auto-indentation?

2012-07-31 Thread John Beckett
Yves S. Garret wrote: How do I turn of _all_ auto-indentation and just have me worry about that stuff? See: http://vim.wikia.com/wiki/How_to_stop_auto_indenting What am I doing wrong and what is the purpose of :close? The :close command closes the current window, whereas you want to close

RE: Installing gvim on Windows with no admin rights

2012-07-25 Thread John Beckett
His Nerdship wrote: I would like the other context menu item Edit with Existing Vim, for example. I don't use that (ZTree is sensational if one is used to it), but apart from send to you might find drag and drop to do the job. Select one or more files in Windows Explorer and dd to gvim. If

RE: i cannot unindent a block

2012-07-24 Thread John Beckett
mascip wrote: i can indent a selected block by pressing TAB or and i'm pretty sure i used to be able to unindent with SHIFT-TAB The basics are explained here, and you might have some mappings similar to these: http://vim.wikia.com/wiki/Shifting_blocks_visually John -- You received this

RE: scripting make and quickfix window behaviour

2012-07-14 Thread John Beckett
Marc Jessome wrote: I'm writing a script that will allow for what I feel is a more comfortable :make + :copen behaviour. Essentially what I am writing is a function that will run :make!, and check if there are errors. It's not quite what you want, but are you aware that :cw opens the quickfix

RE: yank matched portion of a selection of lines

2012-07-08 Thread John Beckett
Andy Wokula wrote: This does what you want (very useful!): http://vim.wikia.com/wiki/Copy_search_matches Somehow all of these solutions are less than ideal. The best solution according to correct pattern matching involves :substitute, but it modifies the buffer. You work around this

RE: yank matched portion of a selection of lines

2012-07-06 Thread John Beckett
Hoss wrote: Ideally, the yanked text would consist of each match within the range, concatenated together with a newline between each. This does what you want (very useful!): http://vim.wikia.com/wiki/Copy_search_matches John -- You received this message from the vim_use maillist. Do not

RE: How to write a text line as binary/Hex with a filename by means of Vim command line(s)?

2012-07-04 Thread John Beckett
William Fugh wrote: If there are 8 chars in one line like this: 52494646 Question: using Vim command line(s), how to write a binary file, and make it 'RIFF' (4 char, not '52494646') in a viewer of TXT? Write a binary file (no newline at end) of characters translated from pairs of hex ASCII

RE: Treat spaces as tabs only at the start of the line

2012-07-01 Thread John Beckett
Gerardo Marset wrote: I have sofftabstop (and shiftwidth) set to 4, and expandtab enabled. Thus, when deleting groups of spaces, vim treats them as tabs and deletes them 4 at a time. I want vim to do that only if from the start of the line and up to the cursor's position there's only spaces

RE: How to tell if highlight has been defined

2012-06-24 Thread John Beckett
On Sunday, June 24, 2012 7:53:11 PM UTC-5, Richard wrote: In a script, is it possible to test whether or not its been defined. Yes, use hlexists('name') for example: if !hlexists('MyHi') hi MyHi guifg=white guibg=black endif An example using it is at: http://vim.wikia.com/wiki/VimTip1572

RE: How to find and replace using negative lookahead

2012-06-08 Thread John Beckett
César Valencia wrote: Hi, I want to find all the strings the has K Value= not followed by and replace them for K Value=1300. This is my original text: K Value=0010, P Value=1025, Z Value=2000 K Value=2051, P Value=0310, Z Value=5110 K Value=, P Value=5025, Z Value=9000 and the

RE: what the current best practice to work with excel file (xlsx)?

2012-06-08 Thread John Beckett
ping wrote: is there any known best way to load my excel data into vim When saving as csv, I thought Excel put quotes around fields that contain commas? I do know that the following tip attempts to handle csv files that contain quoted strings. Also, it has a section on using a Perl script to

RE: Repeat gq from : command line?

2012-06-04 Thread John Beckett
howard Schwartz wrote: That is correct, my typing error. But there is still something wrong with this expression. For instance, when I do simple search with this expression like this: /^[[:lower:][:punct:]]\{3,}/ Vim selects lines that begin with a Capitol letter like these: That's because

RE: Too many instances of vim?

2012-06-01 Thread John Beckett
Shawn wrote: I have used vim for several years now, but recently vim has become painfully slow when it writes to disk. I am checking into other possibilities, but one reason for this (in my mind) might be that I have too many instances of vim up at the same time. I have 48 GB of memory, so

RE: Visual-block Insert text from clipboard

2012-05-31 Thread John Beckett
oversky wrote: In Visual-block Insert operation, is it possible to insert text from register or clipboard to all selected lines? I use mswin.vim, so I press C-Q and select some lines. Second, I press I for Visual-block Insert operation. Then, I press C-V and paste text from clipboard. The

RE: Period in global command

2012-05-25 Thread John Beckett
John Degen wrote: I'm having trouble understanding why there is a period before w in the following command: :'a,'b g/^Error/ .w errors.txt Others have explained that '.' is a range specifying the current line. However, the reason it is needed is that the :w command assume a default range of

RE: silent background execute program cause Vim screen text disappear.

2012-05-25 Thread John Beckett
stardiviner wrote: I write a function like this in .vimrc: function! VimwikiWeblinkHandler(weblink) let browser = 'firefox' execute 'silent !'.browser.' ' . shellescape(a:weblink, 1) endfunction When I press Enter on the link. It will use browser firefox to open

RE: gvim WINDOWID

2012-05-17 Thread John Beckett
David Zelin wrote: Is there anyway to get a vimscript to determine the WINDOWID of the gvim window it's running in? See :help v:windowid Try :echo v:windowid or :put =v:windowid John -- You received this message from the vim_use maillist. Do not top-post! Type your reply below the text you

RE: Help with user defined command

2012-05-16 Thread John Beckett
howardb21 wrote: I want to write a user command that executes this command: :abbreviate exrc ihs somefunction(ihs,irs) CR where ihs and irs are strings I expect you mean expr and not exrc? I must have missed the original thread, but I think it would be good to start again with a statement

RE: Lost file using Vim (first time ever in 15 years)

2012-05-15 Thread John Beckett
To reproduce problem: 1. Create file bad.tmp by executing the following line. :call writefile([Very important file \x8D], 'bad.tmp') 2. Start Vim editing the file and enter commands, as below. vim -N -u NONE bad.tmp :set fenc=cp857 :set nobackup nowritebackup :w 3. Observe message which you

RE: Lost file using Vim (first time ever in 15 years)

2012-05-15 Thread John Beckett
Bram Moolenaar wrote: If a user switches off 'writebackup' he must be prepared for losing work. Perhaps this is not sufficiently clear to the user? Considering how very few times this problem occurs I don't think it is justified to do any work on this. Except perhaps a better explanation

RE: Can't unsubscribe from this mailing list

2012-05-15 Thread John Beckett
A programmer wrote: What's up with that? Sending a message to vim-unsubscr...@vim.org as instructed doesn't give me any reply, and vim-subscr...@vim.org tells me I'm still subscribed I just manually unsubscribed this user. According to the management interface, the user joined the group on 13

RE: Lost file using Vim (first time ever in 15 years)

2012-05-14 Thread John Beckett
Paul wrote: I think you're both right. He should have read the warning message, but also I'm surprised that vim modified the file before being given any instruction to write it. The discussion got very ranty earlier (folks, there is no need to kick the guy, just be glad it wasn't you), and I

RE: Using the quickfix window without losing focus

2012-05-14 Thread John Beckett
Karthick Gururaj wrote: :noremap CR CRC-WC-P Yes, however it should be a buffer mapping, and you might like to use a different key, such as o to open the file: nnoremap buffer o CRC-Wp Put the above line in file ~/.vim/after/ftplugin/qf.vim (Unix) or file $HOME\vimfiles\after\ftplugin\qf.vim

RE: sorting...

2012-05-13 Thread John Beckett
meino.cramer wrote: is it possible to a portion of one line of text alphabetically? There is an example using Python which sorts a whole line at: http://vim.wikia.com/wiki/Use_filter_commands_to_process_text You should provide a before-and-after example of what you mean. Sort words in visually

RE: In function difference let var and let l:var

2012-05-11 Thread John Beckett
Richard wrote: In a function is there a difference in scope, visibility, usage, etc. between using the l: local qualifier and not using it? funcition Foo() { let a1 = 4 let l:a2 = 4 } No. The l: is required only if you want a local variable with the same name as a Vim v: variable

RE: pwd seems to depend on the window

2012-05-11 Thread John Beckett
Paul wrote: The newest version of gvim for Windows seems to have different present- working-directories for each window. Is there anyway to have the old behaviour, where if I do :cd %:p:h on one window to get to the containing folder, the pwd will stay in that folder when I switch to another

RE: How do I tell VIMN to :set number whenever I view a help topic?

2012-05-08 Thread John Beckett
sfosparky wrote: How can I tell VIM that I want it to display line numbering whenever I view a help topic? Create the following file, and any missing subdirectories. The file is ~/.vim/after/ftplugin/help.vim (Unix) $HOME\vimfiles\after\ftplugin\help.vim (Windows) ---start--- setlocal

RE: where can I download vimtips.txt

2012-05-07 Thread John Beckett
I'm using win7. I don't think it would be very useful, but *if* you can find a text-browser for Windows, you could construct a short script based on ViewHtmlText at: http://vim.wikia.com/wiki/Preview_current_HTML_file to read a text version of a random tip from:

RE: Expanding a range of characters

2012-05-07 Thread John Beckett
Yasuhiro MATSUMOTO wrote: more shorter. echo call('range', split('46-58', '-')) Sweet. I did not know about call(). I have slightly lost track of the original problem, but I think this might solve it: function! ShowChars(spec) let result = [] for item in split(a:spec, ',') if

RE: Expanding a range of characters

2012-05-07 Thread John Beckett
The following might be slightly better (and this handles '@-@', but I still haven't read all the docs to see if there is anything else needed; testing needed!): function! ShowChars(spec) let result = [] for item in split(a:spec, ',') if len(item) 1 if item == '@-@' call

Catch error E123: is help correct?

2012-05-06 Thread John Beckett
At ':help :catch' we see this example to catch error E123: :catch /^Vim\%((\a\+)\)\=:E123/ Isn't the above wrong? Why not just: :catch /E123:/ The help example has ':E123' but it means 'E123:'? What is the '^Vim...' stuff for? The messages on my system do not start with 'Vim' (use

RE: E325 even with 'vim -R'

2012-05-05 Thread John Beckett
tuxfan wrote: I would like to start a new vim session on an already open file. I am explicitly invoking the second vim instance in readonly mode, either with 'view' or 'vim -R'. My question is: Why do I still get the E325 error? I am already asking vim to start readonly. This is pretty

RE: Recovery Question

2012-05-05 Thread John Beckett
cjsmall wrote: I have a long standing question regarding vim's recovery mode. When you have a crash and then recover a file, why doesn't vim remove the .swp file after the recovery, as vi(1) does? You are left to remember to clean up manually after a recovery or you will get the same

RE: vim for Windows download problem

2012-05-04 Thread John Beckett
Minev Risto wrote: I'd like to get vim for Windows, however the following .exe does not seem available from this location: ftp://ftp.vim.org/pub/vim/pc/gvim73_46.exe That comes from Sourceforge which, like many other websites, has occasional problems and slowdowns. If there is no hard error

RE: motion t} does not work

2012-05-02 Thread John Beckett
A Loumiotis The motion t{char} does not work when the character I choose is }. Does anyone know why? I use gvim 7.3 on Windows XP. Please spell out what happens and what you expect. Does it work after starting with 'vim -N -u NONE'? On next line, 0vt} correctly selects 'abc{def' on my

RE: good 256 color theme for C

2012-04-30 Thread John Beckett
Chris Jones wrote: Ok, My terminal supports 256 colors, How can i use all the 256 colors in VIM in a non gui terminal. http://vim.wikia.com/wiki/256_colors_in_vim Provided the OP does NOT read the tip and reads Steven Black's comment at the bottom of the page instead :-) Any chance of

RE: Cursor anomoly: apparent and actual positions differ

2012-04-29 Thread John Beckett
I confirm there is a bug (Vim 7.3.509 on Windows). I slightly simplified the example to show the minimum that demonstrates the problem, as below: --- start bug.txt -- To show anomaly, launch Vim as: vim -N -u NONE bug.txt and enter: :so % :13 if v:version =

RE: Indenting/formating

2012-04-25 Thread John Beckett
Gautier DI FOLCO wrote: I known this page but I would go further : the equal sign must have a space before and after, commas should be followed by a space, the keywords of sctructure control (if, switch, for, do, etc.) must be followed by a space before the parenthesis, braces should be on a

RE: :il[ist] with numeric patterns

2012-04-25 Thread John Beckett
Andy Wokula wrote: Many `:[range]' commands accept an optional count as the first argument, apparently this is true for :ilist also: :il 3 20 finds `20' in the text. Not sure if the count has any purpose. Thanks, I was going to propose :ilist to the OP but did not when I could not get

RE: questions about submatch()

2012-04-24 Thread John Beckett
rameo wrote: If I use submatch like this: :%s/'pattern'/\=MyFunction(submatch())/g That gives: E119: Not enough arguments for function: submatch E116: Invalid arguments for function MyFunction(submatch()) I would like to confirm (with a c flag) all single substitutions but the c flag at the

RE: How I can run vim commands from a bash script?

2012-04-24 Thread John Beckett
Antonio Recio wrote: I am trying to write an script to execute a vim command to multiples txt files and to overwrite these txt with the result. Something like that. #!/bin/sh for i in *.txt; do vim :%s/foo/bar/g; done As others have mentioned, that is not going to work well. See the

RE: _vimrc

2012-04-20 Thread John Beckett
hilal Adam wrote: Would experts like Ben Fritz, Marcin, Jurgen share their vimrc files with this forum? Google finds lots of them, but many of those are burdened with baggage. There are two simple samples in these tips: http://vim.wikia.com/wiki/Example_vimrc

RE: echoing the contents of a registry to a /dev device

2012-04-19 Thread John Beckett
Chris Sutcliffe wrote: I guess since I'm the original author of the tip, I should keep it up to date. :) Oh! Thanks for the update, and for crediting me. Another way of doing that is to put a brief mention in the edit summary, because it's not really possible to credit people in tips as just

RE: echoing the contents of a registry to a /dev device

2012-04-18 Thread John Beckett
Tim Chase wrote: You're awfully close, but I think you're reaching for the wrong register. No, @@ is another name for @ (see ':help @r'). Using can cause issues in some circumstances since it starts a comment. It's easy to try this. Yank a couple of words then: :echo @@ The following

RE: echoing the contents of a registry to a /dev device

2012-04-18 Thread John Beckett
Chris Sutcliffe wrote: The following writes @@ (that is, @) to /dev/clipboard:   :call writefile(split(@@, \n), '/dev/clipboard') Works like a charm. However, what the OP should do is build Vim with clipboard support (using :version should show +clipboard). Unfortunately the +clipboard

RE: Setting 'make -jN' in makeprg

2012-04-16 Thread John Beckett
Christian Brabandt wrote: and if you want to add one (or perform other calculations), simply adjust this to (There is no need to do the processing in shell and fork another couple of processes, since vim can do it perfectly well itself): :let makeprg = 'make -j'.(system('grep -c ^processor

Setting 'make -jN' in makeprg

2012-04-15 Thread John Beckett
A new tip suggests a vimrc command to set makeprg so it will automatically detect the number of processors and adjust the '-j' make option. This is out of my league (although I have seen a friend build the Linux kernel using -j16, although I think he gave that up because of the confusing error

RE: Setting 'make -jN' in makeprg

2012-04-15 Thread John Beckett
Christian Brabandt wrote: let makeprg = 'make -j'.system('echo -n $(echo $(grep -c ^processor /proc/cpuinfo)+1 | bc)') Your command looks strange, why are you adding 1 there? I think, better is something like: let makeprg = 'make -j'.system('grep -c ^processor /proc/cpuinfo') Huh, you

RE: how to repeat the last :[range]g with the same range?

2012-04-13 Thread John Beckett
Tim Chase wrote: First, that's a hideous command definition (to the degree I went out to the wiki and changed it to be more legible). you're going to use normal mode, the canonical way to clear a register is to use qaq to clear register a. I prefer the explicit nature of setting it in Ex

RE: How to search in digraphs?

2012-04-12 Thread John Beckett
I needed to look at ':help digraph-table' and noticed something strange. There are 22 lines that have spacegrave at the end, for example: - -N 20138211EN DASH ` However, the grave is hidden in the help. Is there a reason for the grave, or is it a documentation glitch? John

RE: c, s and r

2012-04-11 Thread John Beckett
Niels Kobschätzki wrote: I was wondering what the reasoning behind the existence of c, r and a is. They are all the same but c works with move-commands (like cw) s works with prefixed numbers (like 4s) r doesn't work with anything. Why where three commands for essentially the same thing

Docs for :new

2012-04-11 Thread John Beckett
The ':help :new' text includes: This behaves like a :split first, and then a :e command. Should that read: This behaves like a :split first, and then an :enew command. John -- You received this message from the vim_use maillist. Do not top-post! Type your reply below the text you are

RE: Question about WatchForChanges

2012-04-07 Thread John Beckett
Leo wrote: I have the following setup. I'm editing a file in vim and have multiple windows open I have a shell script that I run from another window, which externally modifies the file while it's still open with vim. I don't think you said what you _want_ to happen. Say you use Vim to edit

RE: Paste whole block by line number

2012-04-03 Thread John Beckett
horsecandy wrote: My current method for pasting blocks of code is to select them in visual mode, copy/yank them, and paste. Frequently I see a line or two that I would like to copy or move to another line without going through this hassle. Is there a command that can be used to move or copy

RE: Write register contents to file

2012-04-01 Thread John Beckett
howard Schwartz wrote: I would like to write the contents of a register to a file. Easy enough to grab the contents with let variable = getreg('a'). It would then be easy if :echo variable file worked like unix echo, but it doesnt. Any simple way to get contents of some register a into a

RE: MRU plugin

2012-03-30 Thread John Beckett
Tarlika wrote: http://www.vim.org/scripts/script.php?script_id=521 I have been using this excellent plugin for some time, mainly with Files-Recent Files in gvim. There doesn't seem to be a user option for opening files in new tabs. I don't use the menus in gvim. After entering :MRU (or

RE: scripts spam

2012-03-28 Thread John Beckett
jeroen wrote: It seems that a spammer is/has been very active in the scripts section of the vim site: http://www.vim.org/scripts/index.php... :/ Thanks. I have deleted all of it (9 scripts). I have checked each day for quite a while, but I did not check today... John -- You received this

RE: :set nu - how to copy lines with line numbers?

2012-03-26 Thread John Beckett
Paul Nguyen wrote: On my Windows VIM GUI, :set nu, and then hold down Ctrl-Shift while highlighting the desired text with the mouse. This yanks the line numbers into the buffer. :help gui-mouse-modeless Never heard of that, although it turns out that I do use it when output is displayed. For

RE: Press ENTER or type command to continue behavior is different between gvim and terminal vim

2012-03-23 Thread John Beckett
John Little wrote: This is probably related to 'cmdheight'. How so? cmdheight=1 in both cases. That was not mentioned by the OP, and while it's possible/likely to be the case, I was guessing that the vim and the gvim might have different configs. John -- You received this message from the

RE: Press ENTER or type command to continue behavior is different between gvim and terminal vim

2012-03-22 Thread John Beckett
H Xu wrote: For the following vim script in a tmp.vim file: :!echo 1 :!echo 2 When executing :so tmp.vim in a terminal vim (I'm on Konsole of KDE), the output is like this: 1 Press ENTER or type command to continue 2 Press ENTER or type command to

RE: Get canonical (normalized) file name

2012-03-17 Thread John Beckett
Timothy Madden wrote: Actually there still is. A simple example program shows that ::GetLongPathName() has this effect, though admittedly it is not explicitly documented as such. Thanks! It is a long time since I searched for methods to get the true name of a file, and I did not find that.

RE: Get canonical (normalized) file name

2012-03-14 Thread John Beckett
Timothy Madden wrote: I am really wondering, what the right case is on Windows and what do you need it for? The Windows file system (NTFS) may be case-insensitive, but it is still case-preserving. File names are written and stored in the file system preserving the letters' case at all times.

RE: Move current line up

2012-03-13 Thread John Beckett
Yannik Sembritzki wrote: Works! Thank you :-) This tip (at Mappings to move lines) has more: http://vim.wikia.com/wiki/Moving_lines_up_or_down By the way, please bottom post on this list. Quote a small (relevant) part of the message you are replying to, and put your text underneath. Delete

RE: DirDiff Error With Spaces

2012-03-09 Thread John Beckett
Stephen Rasku wrote: Bingo! Changing vimdiff configuration in .hgrc from: ... There appears to be a bug with the way that Windows XP cmd.exe handles the quoting, and the documented procedure fails for me. Stephen has updated the docs:

RE: vimrc - split and resize windows, in gVim - how to do it ?

2012-03-04 Thread John Beckett
NEW USERS ON THIS MAILING LIST: Please bottom post on this list. Quote a small (relevant) part of the message you are replying to, and put your text underneath. Delete text that is not needed to understand your reply. See the footer below each message (Do not top-post!). John -- You

RE: I KNOW YOU MUST HAVE...

2012-02-20 Thread John Beckett
Federal Reserve spam deleted from Google Groups, and sender banned. Don't know how it got through. John -- You received this message from the vim_use maillist. Do not top-post! Type your reply below the text you are replying to. For more information, visit http://www.vim.org/maillist.php

RE: Vim Script Spam

2012-02-18 Thread John Beckett
Marc Weber wrote: At any rate, I have deleted the following scripts and their download packages: 1301, 1476, 1670, 1789, 2664. Those other packages - did they contain some strange downloadable content as well? The above scripts each had an image (not relevant to Vim) for the package

RE: How to display line end like in this vim video?

2012-02-17 Thread John Beckett
Peng Yu wrote: I do not mean to type that character. I just need vim to display that character by default at the line ends. See the examples in this tip (in particular, 'listchars'): http://vim.wikia.com/wiki/Highlight_unwanted_spaces John -- You received this message from the vim_use

RE: Vim Script Spam

2012-02-17 Thread John Beckett
Marc Weber wrote: The contents (image pixels) of 921798641_e656ca83e8.jpg are exactly the same as on flickr (diff exit code 0). ... Thanks for the analysis. It hadn't occcurred to me to look for the images or a cache of the user/script. My theory: A user created a valid Vim script. A year or

RE: Vim Script Spam

2012-02-16 Thread John Beckett
http://www.vim.org/scripts/script.php?script_id=1670 Thanks, Bram has alerted me to that. I will be deleting it (and some related stuff) in about 24 hours. John -- You received this message from the vim_use maillist. Do not top-post! Type your reply below the text you are replying to. For

RE: The Super Search and Vim Scripts for Python

2012-01-31 Thread John Beckett
gberar wrote: I installed some Python specific Vim scripts and found that, when editing python files, the Super Search does not behave as it does normally. If I have the cursor over foo in the string foo.bar and type the character *, vim will search for the string foo as long the file is

RE: Question about searching in VIM

2012-01-27 Thread John Beckett
Rolf Nick wrote: What do I need to put in my _vimrc file so that VIM automatically executes the search command with every character I enter **before** I press Enter. :set incsearch The main points are here: http://vim.wikia.com/wiki/Searching John -- You received this message from the

RE: forcing variable storage to viminfo

2012-01-22 Thread John Beckett
sinbad wrote: i am assuming that the variables will be stored in viminfo file only when we exit the vim, is it possible to force the variable storage into vim info file. Apparently yes. After ':help viminfo', scroll down to the MANUALLY READING AND WRITING section. I believe you have to

RE: change vim limitation of maximum tabs/buffers?

2012-01-21 Thread John Beckett
ping wrote: I'm using vim to open a lot of text files , each in a tab (a buffer), it looks I reached the default maximum concurrent file numbers (30) and get a warning. I can't open more files then. google searching doesn't bring much info. anyone ran into similiar issue and any hint? What

RE: Vp vs Vp

2012-01-21 Thread John Beckett
David Fishburn wrote: I am trying to figure out why I see different behaviour when performing what I consider identical actions. Strange, I see that too (also with Vim 7.2.18). BTW the first Shows 1 should be Shows 2. The issue is as follows: start with two lines: 123 456 1. Press Y

RE: Request for search/replace upgrade, not wholesale replacement!

2012-01-18 Thread John Beckett
Gary Johnson wrote: How do you see a wiki page fitting into this? If I have to contact each of the authors individually anyway, wouldn't it be as easy or easier to include that information in the message to them? Yes, that's fine (and thanks for undertaking to do it!). I was thinking it

RE: Request for search/replace upgrade, not wholesale replacement!

2012-01-17 Thread John Beckett
Gary Johnson wrote: I was surprised at that figure, so I took a look myself. I found 34 files in $VIMRUNTIME/syntax with that problem! I'd be willing to fix at least some of them except that almost all of them are for languages that I never use and know nothing about, so I don't think I'd do

RE: ignore new line in search

2012-01-15 Thread John Beckett
Pau wrote: huge document to find the place where I have to resume work or do modifications. Unfortunately, the search function stops in a new line, so that if I look for a very interesting place which was far away vim will not find it if there is a new line, i.e. something like this a very

RE: vimdiff: ignore linebreaks

2012-01-13 Thread John Beckett
Claus Atzenbeck wrote: One can remap hjkl to go line by line visually Something to be tested. I remapped hjkl to go by visual lines. Let's see how it goes. You can make hjkl work well, but the diffs still suck. Vim shows diffs on a line by highlighting all text from the first change on the

RE: game alternosfera

2012-01-11 Thread John Beckett
TeRanEX wrote: This new script looks rather 'fishy' to me: http://www.vim.org/scripts/script.php?script_id=3876 Thanks. Script, download and user all deleted. John -- You received this message from the vim_use maillist. Do not top-post! Type your reply below the text you are replying to. For

RE: Bad Script

2012-01-05 Thread John Beckett
Paul wrote: Subject: Bad Script http://www.vim.org/scripts/script.php?script_id=3867 Thanks. I have been watching for spam every day or so. This one is new. I went to delete it, and prepared to first copy the data so I have a record of what's been happening. While I was doing that, someone

RE: why is Vim coloring text in txt files?

2011-12-28 Thread John Beckett
wolfv wrote: I tried this from cmd window: C:\Users\wolf cd %HOME% The system cannot find the path specified. It's a long story, some of which is mentioned at: http://vim.wikia.com/wiki/Filetype.vim (search for $HOME). The simplest is to use Vim to find what it thinks: :echo $HOME Then

RE: Unsubscribe please

2011-12-27 Thread John Beckett
Kote Dekuur wrote: Sorry for the mass mailing.. anyone knows how to unsubscribe from the mailing list as the following unsubscribe mailing doesn't work. vim-announce-unsubscr...@vim.org The above address is to unsubscribe from the vim_announce group. At the bottom of each mail there is a

RE: block edit possibility

2011-12-17 Thread John Beckett
sergio wrote: When file is read only and I change mode to insert vim just warns me that file is read only. But it allows to type. Is it possible to block edit possibility at all? :setl noma :help 'modifiable' John -- You received this message from the vim_use maillist. Do not top-post! Type

RE: password generator

2011-12-16 Thread John Beckett
Steve Hall wrote: The best passwords include the most character possibilities. This crazy notion websites/software have of restricting them to certain characters or counts only means less security because they are more easily guessed. Off topic for Vim, but it's worth knowing that length

RE: regex: AND operator

2011-12-16 Thread John Beckett
Robert Chan wrote: I'm wondering if there's a more compact way to match both 'foo' and 'bar' appearing on the same line than: \(foo*bar\)\|\(bar*foo\) See Finding two words in either order at: http://vim.wikia.com/wiki/Search_patterns John -- You received this message from the vim_use

RE: karma wrecking problem

2011-12-15 Thread John Beckett
More info on the rating attacks at vim.org/scripts: Scripts with large negative ratings are shown at: http://www.vim.org/scripts/script_search_results.php?order_by=ratingdirection=ascending Some old spam is shown in the above results. I will delete it in a day or two. I was wondering if the

RE: karma wrecking problem

2011-12-14 Thread John Beckett
hsitz wrote: I'm author of the VimOrganizer plugin. http://www.vim.org/scripts/script.php?script_id=3342 ... It appears that there were 22 or 23 votes today, all for -1 karma. Some preliminary findings for the ratings of script 3342: Things look normal up to 2011-12-14 00:26. In the next 12

RE: karma wrecking problem

2011-12-14 Thread John Beckett
John Beckett wrote: Things look normal up to 2011-12-14 00:26. In the next 12 seconds, there were 22 ratings of -1, each from a different IP address. I misread the timestamps: it was 15 minutes (not 12 seconds). I also noticed that script 3025 had 231 ratings of -1 in 1h21m starting 2011-12

RE: karma wrecking problem

2011-12-13 Thread John Beckett
hsitz wrote: I'm author of the VimOrganizer plugin. http://www.vim.org/scripts/script.php?script_id=3342 Earlier today it had a little over 1100 downloads -- maybe 1105 to 1110 -- with around 35 votes and 120 or 125 total karma. I just checked the page and it now has jumped up to 1133

RE: use of redir = variable

2011-12-12 Thread John Beckett
rodinski wrote: It works well except it seems to expand horizontal tabs to spaces. The code you posted uses :redir to capture the output of a command. I imagine that tab characters are converted to spaces before the command's output is displayed, so the captured output would have no tabs. In

RE: create line break

2011-12-09 Thread John Beckett
stosss wrote: I want to do :%s@\(br /\)\(1\)@\1linebreak\2@ and have it find br /1 and return: br / 1 I'm not sure what return means, but the following will change each br /1 by inserting a newline before the 1. :%s@\(br /\)\(1\)@\1\r\2@g I would be inclined to replace br / with br\s*/.

RE: Scrolling Long Lines Revisited. Again.

2011-11-29 Thread John Beckett
James Cole wrote: This seems like a perennial topic[1], that regularly gets dismissed -- vertically scrolling by screen lines vs. real lines. I feel the same way. So do I, as I have recently done some editing of text where a paragraph is a long line (possibly thousands of characters).

RE: expression register as calculator with floats?

2011-11-29 Thread John Beckett
John Little wrote: Just be sure to specify floating point numbers even for any integers involved, e.g. 59.0 instead of just 59. Why you make this proviso? F. ex., vim evaluates 59 + 37.5 as 96.5. For safety: 4/12 is 0 but 4/12.0 is 0.33. Also, integer operations can overflow sooner. On

RE: strip whitespace and carriage returns from end of file

2011-11-25 Thread John Beckett
Chris Lott wrote: I have the following shortcut to strip whitespace from the end of a file: nnoremap leaderW :%s/\s\+$//cr:let @/=''CR There is a slightly superior mapping at: http://vim.wikia.com/wiki/Remove_unwanted_spaces How can I have that command also strip all trailing carriage

RE: Another Spam Script

2011-11-25 Thread John Beckett
Paul wrote: This just appeared: http://www.vim.org/scripts/script.php?script_id=3822 Thanks. I just deleted 8 spam scripts (the above and some others that I have recently noticed). Of those, one was created last March and is unrelated to the others. The other 7 were created in the last month

RE: Backporting script to vim 6.3 (need help)

2011-11-24 Thread John Beckett
Preben Randhol wrote: I have made some vimscripts for Python programming. I made them for Vim 7.0, but now I need to get them to work on Vim 6.3 as I have to work on a system where I cannot update Vim. Sorry to ignore your question (I don't know the answer), but you do know that you can build

Dubious scripts at vim.org

2011-11-23 Thread John Beckett
After a report of a spam script (now deleted), I did a quick scan of recent scripts. That shows another ten dubious scripts which need to be deleted (I'll handle those). But what about this: http://www.vim.org/scripts/script.php?script_id=3811 It has no English description, and the download is a

<    1   2   3   4   5   6   7   8   >