'set paste' toggles 'set ruler': why?

2017-03-14 Thread Eli the Bearded
Of all the things the ':set paste' setting does, only ':set noruler' puzzles me.[*] Why should informational settings be surpressed with a setting for input? Can this please, please, be changed? [*] Alright. The ':set noshowmatch' is also puzzling, but I rarely have showmatch enabled.

Re: 'set paste' toggles 'set ruler': why?

2017-03-15 Thread Eli the Bearded
h_east wrote: } This behavior is documented. I am 100% aware that it is documented. What is **not** documented is why. Christian Brabandt wrote: > https://github.com/vim/vim/issues/184 | Pasting can involve a large amount of text (someone just

an old "hack" of mine, shared for amusement

2017-04-24 Thread Eli the Bearded
I found this today, while looking for abandoned swap files on my computer. The file was dated 2006, but the swap file is for vim 4.2, and the hostname is one I last used ~ 1998. I guess I copied the file, and the swap file, from a backup or something in 2006. $ ls -l my-src/hacks/vi/fork

Re: an old "hack" of mine, shared for amusement

2017-04-25 Thread Eli the Bearded
Christian Brabandt wrote: > Are you saying, original Vi could be tricked to execute various commands > via modelines? That sounds pretty scary actually. Still can, if you have real vi somewhere. (You can also embed arbitrary ex commands in tag files for real vi.) Elijah -- -- You received

Re: an old "hack" of mine, shared for amusement

2017-04-25 Thread Eli the Bearded
Erik Falor wrote: > I can report that this "hack" doesn't do anything interesting as of Vim 5.5. > It doesn't complain about the pipe characters in the modelines, though. Everyone seems to be missing it. rot13 solution for those interested. Guvf *unpx* jnf qrfvtarq gb *abg* jbex va ivz. Vg

scrolloff side effects are bothersome

2017-10-10 Thread Eli the Bearded
I've long used scrolloff intermittantly, but recently I tried adding it to my vimrc. I'm finding myself unhappy now. Straight from the scrolloff docs: *'scrolloff'* *'so'* 'scrolloff' 'so'number (default 0, set to 5 in |defaults.vim|)

Re: scrolloff side effects are bothersome

2017-10-11 Thread Eli the Bearded
Tony Mechelynck wrote: > I don't use H/M/L but I do use PgUP/PgDn (whose effects are different) > though never with an operator. My usual 'scrolloff' setting is 6. I've been using H/M/L since before Vim existed. Frequently PgUp/PgDn did not work without a manual :map in those days, and many

Re: scrolloff side effects are bothersome

2017-10-12 Thread Eli the Bearded
Bram wrote: > Hmm, it's possible to make these commands not use 'scrolloff' when an > operator is pending. It won't be consistent with other operations > though. But it does make sense when 'scrolloff' is a large number, > since it's then hard to estimate what text will be covered. While the >

Re: How to handle non-ascii characters?

2017-10-23 Thread Eli the Bearded
Barry Gold wrote: You wrote: > I'm impressed that you can type your entire vimrc from memory. I'm > tempted to use some of that. If only I _understood_ it. Well the normal stuff that applies globablly. Stuff for specific classes of files is a bit more difficult. :^) It's basically these three

Re: How to handle non-ascii characters?

2017-10-23 Thread Eli the Bearded
Barry Gold wrote: > None of these looks like themselves when I edit the file with vim in a > cygwin Terminal window. I can search for [^ -~^t] to find the non-ASCII > characters, then go to the original word document to find out what the > correct character is. If I had only a few of these, that

Re: Vim surprisingly slow?

2017-11-14 Thread Eli the Bearded
Tim Chase wrote: > :g/.*name":"\([^"]*\)".*card":"\([^"]*\)".*/let > s=substitute(getline('.'), '.*stamp":"\(\d\+\)-\(\d\+\)-\(\d\+\).*', > '\1\2\3','').'.txt'|s//\1,\2/|exec ".w!>>".s > which works. But for some reason, it is *painfully* slow on my > machine. Just do one write.

Re: Vim surprisingly slow?

2017-11-16 Thread Eli the Bearded
Tim Chase wrote: > :g/.*name":"\([^"]*\)".*card":"\([^"]*\)".*/let > s=substitute(getline('.'), '.*stamp":"\(\d\+\)-\(\d\+\)-\(\d\+\).*', > '\1\2\3','').'.txt'|s//\1,\2/|exec ".w!>>".s > which works. But for some reason, it is *painfully* slow on my > machine. Just do one write.

100000ii

2018-05-14 Thread Eli the Bearded
Prompted by a challenge here: https://fivethirtyeight.com/features/pirates-monkeys-and-coconuts-oh-my/ (Near the bottom of the page, in the answers to the previous challenge dealing with editors.) I tried inserting a million letter "i"s into a new buffer with vim. Oh, how insanely slow it was.

Re: "best" terminal library for vim

2018-06-26 Thread Eli the Bearded
On Sat, 23 Jun 2018, tu...@posteo.de wrote: > currently I am setting up a Raspberry Pi Zero W for being used > as "commandline server" ;) ... > The configure stage did not find a terminal library on the system > (which is kinda weird, since Midnight commander is installed ... > and it looks like

Re: Vim Display Corruption

2018-08-10 Thread Eli the Bearded
Richard Riegner wrote: > I run an xterm window on macOS and ssh into a > remote Linux machine. The edit session is > displayed back to an XQuartz server running on > the same macOS. I have seen lots of problems with that sort of setup: local Mac with XQuartz and xterm used to remote ssh

editing textareas in Firefox with vim

2018-08-24 Thread Eli the Bearded
This is really a Firefox issue, but I figure this list might have a better set of people to tackle it than mozilla.support.firefox. At one time, Firefox had a wide open (read: slow and security issue prone) extensions API. At that time I could use an extension called "It's All Text". With one

Re: editing textareas in Firefox with vim

2018-08-28 Thread Eli the Bearded
Michael Henry wrote: > Perhaps one last idea for debugging problems with textern; you > might close Firefox, rename ``~/.mozilla`` out of the way, then > restart Firefox to generate a new profile, then see if you can > make textern work.  I recently had to do this myself to solve a > weird Firefox

Re: editing textareas in Firefox with vim

2018-08-26 Thread Eli the Bearded
Michael Henry wrote: > I've been using "textern" for this, though I don't use it > heavily.  It's working for me on Ubuntu 16.04 with Firefox > 61.0.1 and GVim 8.1.290.  Here are the steps I followed to > install: > > - Install URL: >   https://addons.mozilla.org/en-US/firefox/addon/textern/

Re: Vim Android App with encrptioin support

2018-01-22 Thread Eli the Bearded
Jeffery Small wrote: > I have an android phone. I want to be able to view some > blowfish2-encrypted files that I have placed on the phone. Does anyone > know of a vim app that supports decryption? I have the "Vim Touch" app > installed, but it complains that the content is "too big" when

Re: using "gf" or "^Wf" with symlinked files?

2018-11-05 Thread Eli the Bearded
Tim Chase wrote: > (the actual context is a remind(1) reminder file where ~/.reminders > is a link to ~/.config/remind/reminders.rem which includes each of my > individual calendar files are in that ~/.config/remind/ directory, so > editing ~/.reminders doesn't give me quick access to the

vim --cmd ':set paste'

2018-11-05 Thread Eli the Bearded
If I use "vim --cmd ':set paste' filetoedit" when one of the exrc files[*] will "set autoindent", then I find autoindent is in effect when I start to edit. Tested with: VIM - Vi IMproved 7.2 (2008 Aug 9, compiled Feb 17 2012 10:24:10) Included patches: 1-411 VIM - Vi IMproved 8.1 (2018 May 18,

from the old vi faq

2018-09-30 Thread Eli the Bearded
http://www.faqs.org/faqs/editor-faq/vi/part2/ -- start quote 8< -- 6.1 - Silly vi tricks Note: Also check out the Silly macros down below. Many macros and tricks are interchangeable. xp This will delete the character under the cursor, and put it afterwards. In other words, it

Re: What is the quickes way to delete spaces in front of each line?

2018-09-19 Thread Eli the Bearded
Igor Forca wrote: > Now reading Recardo's post (second post in thread) and playing around I have > found there is: > diw > j. > j. > j. > j. > > Which is exactly what I was looking for. No need for count (ed command), or > no need for selecting for video. "diw"? That's some vim-ism, isn't it?

Re: Evaluating the cost to type something in vim

2019-01-25 Thread Eli the Bearded
On Thu, 24 Jan 2019, Peng Yu wrote: >> finding the minimal user input that yields a buffer with the input >> falls under https://en.wikipedia.org/wiki/Code_golf > This kind of competition is not relevant to what I am not talking > about. One has to spend extra effort to come up with the absolute

:new and :tag

2019-08-26 Thread Eli the Bearded
I find myself often wanting to open a new buffer and then lookup a tag. In visual mode, I can use while on top of a tag word. In ex (command line) I have been using: :cmap ,nt new\|tag and then typing ":,nt" which expands before my eyes to ":new|tag". But I keep feeling like that's a feature

Re: :new and :tag

2019-08-26 Thread Eli the Bearded
Yegappan Lakshmanan wrote: > Did you try using the ":stag" command? This command splits the window and > then jumps to the specified tag. No, I had not. And that looks to be the command I was overlooking. Thanks. Elijah -- -- You received this message from the "vim_use" maillist. Do not

Re: Unwanted underline

2019-09-05 Thread Eli the Bearded
JH wrote: > Wow, that makes different, it displays color, no underline any more, > how can I run the vim without --clean? > > Also, I use .vimrc configure, what the statement can I add to .vimrc > to turn the color off? You might like ":syntax off". I have that in my .vimrc. But to outright

Re: Persist Clipboard after Exiting Vim

2019-08-06 Thread Eli the Bearded
Tony Mechelynck wrote: > Michael Partridge wrote: >> Is there a way to prevent the clipboard buffer from being cleared upon >> exit? This shows a fundamental misunderstanding of the clipboard in X11. It is not a place where stuff is stored, but a promise to supply content by a running app. When

R.I.P. John Conway

2020-04-14 Thread Eli the Bearded
Many years ago I wrote Conway's Game of Life in vi macros. Not vimscript, macros. I posted them, uuencoded, to comp.editors where you might still find them with Google Groups searches. But Bram Moolenaar liked the effort, so you can still find those macros easily. On my Ubuntu system, they are

Re: Meta: reading file from stdin while still interacting with the terminal

2020-04-20 Thread Eli the Bearded
(Sent directly and to list; list moderator -- if any -- is welcome to reject this.) Tim Chase wrote: > I'm playing around with a curses program and would like it to behave > similarly to how vim lets me do > >$ echo hello | vim - > > where vim reads data from stdin but then interacts with the

Re: Runtime of record/play feature

2020-05-14 Thread Eli the Bearded
Manas wrote: > Hi, I was recently working on a large CSV file in Vim. I needed to do > some changes in the file and I utilized the recording feature for it. > Recording feature is really awesome and worked well for my use case. > > However working on a file whenever applied on multiple lines,

Re: Encryption is not considered a change by the :x command

2020-05-11 Thread Eli the Bearded
Tony Mechelynck wrote: > Ninu-Ciprian Marginean wrote: >> When we look at the quickref documentation we find: >> If we open an existing file and we do not do any changes except for >> changing the encryption key(with the ":X" command) and then use the ":x" >> command to exit, the changes to the

issue subtituting new lines

2020-05-19 Thread Eli the Bearded
I use several versions of vim throughout the day, all inside xterms, and some inside tmux running in an xterm. Some versions of vim I have noticed break my long standing way of adding newlines in a :s/// substitute command. To make all %% sequences turn into a new line, what I'd type is: colon

Re: issue subtituting new lines

2020-05-19 Thread Eli the Bearded
Christian Brabandt wrote: > On Di, 19 Mai 2020, Eli the Bearded wrote: >> And that would look like this in vi, nvi, and vim up until recently: >> :%s/%%/^M/g >> On the versions that break that, it instead looks like this: >> :%s/%%/^[[27;5;109~/g > A featur

Re: Matching « and »

2020-09-09 Thread Eli the Bearded
gevisz wrote: > What line(s) of code should I add to my vimrc so that ci« behave in > the same way with respect to « and », as ci( behaves with respect to ( > and )? Hmmm. "set matchpairs=(:),{:},[:],<:>,«:»" works fine for %, but it appears that i(, i<, i{, a(, and the like are special

Re: Usage of | character in digraphs

2020-05-27 Thread Eli the Bearded
Manas wrote: > For example, I want to add ℕ (symbol for natural numbers set) as N| (N > : digraphs N| 8469 > it is throwing E474. The | character separates commands in ex-mode. You can use it in your digraph, but you need to backslash escape it: : digraphs N\| 8469 The ex-mode | thing dates

encoding local to part of a buffer?

2020-12-08 Thread Eli the Bearded
The "Changing encoding of an already loaded buffer" thread reminds me that there are times I'd like to be able to look at a region of a file in one encoding, and another region in a different encoding. Say, tell vim everything between mark j and mark k is UTF-8 while everything between mark u and

W16: Warning: Mode of file has changed

2020-11-10 Thread Eli the Bearded
Help has this to say: *W16* Warning: Mode of file "{filename}" has changed since editing started When the timestamp for a buffer was changed and the contents are still the same but the mode (permissions) have changed. This usually

Re: Insert non-rectangular selection

2021-05-26 Thread Eli the Bearded
:r! reply-body --top '/tmp/Re1BDLjSqOg3' On Tue, 25 May 2021, Andre Tann wrote: > I repeatedly have the following situation, and wonder how it can be > handled better than I do it now. These lines must be merged > > /path;text > /path;text > /path;text > > with these: > > /subdir > /longsubdir >

Re: Find unnamed swap file

2021-07-06 Thread Eli the Bearded
Julius Hamilton wrote: > I am using Gvim on Andronix, Android Linux, and it suddenly goes down > sometimes. I can recover any documents that were named with the .swp file > recovery menu. Is there any way I can search for .swp files for files that > hadn't been initially saved and named yet? In

Re: How to specific the line to go to from the command line?

2021-03-24 Thread Eli the Bearded
Sven Guckes wrote: > * Peng Yu [2021-03-24 01:51]: >> I want to specify the line number to go to at the command line. >> Could anybody let me know how to do it with vim? Thanks. > > how to go to line #23: > > jump to line 23 on startup: > vim +23 filename That's a good answer. The more

Re: How to specific the line to go to from the command line?

2021-03-24 Thread Eli the Bearded
Tony Mechelynck wrote: > Yes, and as icing on the cake, a variation on this one: how to go to a > specific line and column: > > " Go to line and column > function GoTo(line, column) > exe min([line("$"), a:line]) "| normal" a:column . "|" > endfunction You don't need a vim function to do

Re: vim-mnemonics for hjkl.

2021-03-04 Thread Eli the Bearded
Csaba Hoch wrote: > Some years ago I read a mnemonic from the perspective of Japan: > > Kamchatka > ^ > | > Hong Kong Los Angeles > | > V > Java/Jakarta That is the

Re: How to delete from the current cursor position to a particular character on the same line?

2021-02-26 Thread Eli the Bearded
On Fri, 26 Feb 2021, Joseph Wulf wrote: > I've a common problem that I've never been able to find a solution for. ... > With my cursor at "B" how can I delete from the current cursor position > (col 18) to the first double-quote mark (") efficiently? Delete up to a quote mark later in the line:

Re: Some basic Vim commands

2021-04-17 Thread Eli the Bearded
Julius Hamilton wrote: > I can jump to the beginning of some text on a line that begins with > whitespace with v, w, h, d. Is there a single command to delete all initial > whitespace on a line? I'd typically do that in either of two ways: : {range} s/^[ TAB]*// With a {range} like

Re: '%' matches but it doesn't when executed

2022-03-23 Thread Eli the Bearded
Adri Verhoef wrote: > Hi, I've been using Vi and Vim since the eighties. My current Vim > version is 8.2.4579, provided by Fedora Linux. > > I have this line in a file: > > > When the cursor is on the first or second [, then the matching ] lights up. > When the cursor is on the first [ and I

Re: % and matchpairs

2022-06-08 Thread Eli the Bearded
On Mon, 6 Jun 2022, "'Grant Taylor' via vim_use" wrote: > #TIL > > Thank you for sharing this Eli. I'll be trying ~> using a subset of this. > > Aside: How wrong is it that I'm thinking about adding m4's "`" and "'" > based on file / buffer type? a la. set matchpairs=`:' Not wrong at all.

% and matchpairs

2022-06-05 Thread Eli the Bearded
One neat thing about vim is configurability. I think it's widely known (and done) to add < and > to matchpairs for %, but you can add Unicode pairs in the list to, for smart quotes and quote styles not used in English (at ast not often). I decided to try the extreme and described my method here:

Re: Error make vim on termux terminal

2023-04-05 Thread Eli the Bearded
hence jack wrote: > According to the error message, I add the explicit declaration for " > *setpwent"* and "*getpwent"* function at src/misc1.c, and it works, ... > Has anyone had this problem?藍 Have you tried the build configuration in the Termux packages repo?