Tuesday, April 1, 2025

Re: StackExchange is a sad thing too

Without wanting to continue participating in this topic's interchange of points/arguments, beyond this contribution, I just want to say that I fully agree with what Marc offered in his reply regarding the advantages of older technologies that have become disused, likely because people, being people, are generally lazy and want a SPOC for all things, and only to willing and eager to leave it to others to "take care of my backups", hence the explosive adoption of things like Facebook, Twitter, etc. ... which are not desktop-based, leaving everyone at the mercy of "them" in remote places.  Just another facet of what can only be described as a long game-for destroying physical (i.e. neighbourhood) communities of like minds by eventually pulling the plug on those centralized services.

Such blind mass-adoption that I feel can only be characterized as behaviour similar to lemmings or dodos, and we know what happened to the latter!  Hence why I keep my email client, and all such personal information, in my own hands at the desktop.

I will still have ALL my resources when the internet fails, as long as a nuke hasn't fried my computer.  🙂


Eric

P.S.  This is my email setting for all things. Thank you for understanding.


On 2025-04-01 05:30, Marc Chantreux wrote:
I Ben and thanks for sharing this feeling,    On Mon, Mar 31, 2025 at 08:24:16PM -0400, D. Ben Knoble wrote:  
thanks for this pointer. so sad those questions arise in stack* as we have a  user mailing list.  
  I'm sorry to hear you feel that way; the goal of the StackExchange  project was to create a commons of high-quality resources (much like  Wikipedia has).  
  Wikipedia came out to fill the gap of collaborative places to edit  articles.    StackExchange just split communities because previous tools (mailing  lists, newsgroups, archives and FAQ) were so much more convenient but  in the early years of this millenium, lot of people came to internet  with no idea of habits and customs of the technical communities.    If it was ignorance, that's very sad. If not, I'll be happy to learn  abou arguments that was worth splitting communities.    
I think the linked examples are good examples of this  (though if you visit the home page you will find more sand than pearls  these days, at the cost of having helped a great number of people).  
  Did you try newsgroups or mail archives? did you enjoy having your own  local workflow with mbox mirrors indexed so you can use mutt of  maildir-utils to query them, add copies of posts or threads in your  notes and things like that?    StackExchange will never reach this level of convenience. Not to mention  it's so painful to have a decent conversation through html text ereas.  especilly for vim or emacs users.    I don't know if StackExchange has an API (I'll be happy to learn about  it) so I can include it in my workflow but nevertheless: It's extra work  for same result :(    
Mailing lists are great, and they serve a different purpose for me  (cf. the recent extended discussion which might ultimately be boiled  down to a high-quality Q&A pair if desired).  
  So how do you set the cursor between mailing lists and StackExchange?    We all know the story of questions that looks insignifiant at start  being the root of a giant threads with very interesting perspectives.    Another point against StackExchange: those kind of threads are so  painful to follow in a web page.    I couldn't imagine that people could be found of StackExchange  so I'm really grateful you shared about it.    regards.    

StackExchange is a sad thing too

I Ben and thanks for sharing this feeling,

On Mon, Mar 31, 2025 at 08:24:16PM -0400, D. Ben Knoble wrote:
> > thanks for this pointer. so sad those questions arise in stack* as we have a
> > user mailing list.
>
> I'm sorry to hear you feel that way; the goal of the StackExchange
> project was to create a commons of high-quality resources (much like
> Wikipedia has).

Wikipedia came out to fill the gap of collaborative places to edit
articles.

StackExchange just split communities because previous tools (mailing
lists, newsgroups, archives and FAQ) were so much more convenient but
in the early years of this millenium, lot of people came to internet
with no idea of habits and customs of the technical communities.

If it was ignorance, that's very sad. If not, I'll be happy to learn
abou arguments that was worth splitting communities.

> I think the linked examples are good examples of this
> (though if you visit the home page you will find more sand than pearls
> these days, at the cost of having helped a great number of people).

Did you try newsgroups or mail archives? did you enjoy having your own
local workflow with mbox mirrors indexed so you can use mutt of
maildir-utils to query them, add copies of posts or threads in your
notes and things like that?

StackExchange will never reach this level of convenience. Not to mention
it's so painful to have a decent conversation through html text ereas.
especilly for vim or emacs users.

I don't know if StackExchange has an API (I'll be happy to learn about
it) so I can include it in my workflow but nevertheless: It's extra work
for same result :(

> Mailing lists are great, and they serve a different purpose for me
> (cf. the recent extended discussion which might ultimately be boiled
> down to a high-quality Q&A pair if desired).

So how do you set the cursor between mailing lists and StackExchange?

We all know the story of questions that looks insignifiant at start
being the root of a giant threads with very interesting perspectives.

Another point against StackExchange: those kind of threads are so
painful to follow in a web page.

I couldn't imagine that people could be found of StackExchange
so I'm really grateful you shared about it.

regards.

--
Marc Chantreux

--
--
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

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/vim_use/Z-uyPoeEHOSoy15M%40prometheus.

Monday, March 31, 2025

Re: debuggable vimfiles

On Sun, Mar 30, 2025 at 3:52 PM Marc Chantreux <mc@unistra.fr> wrote:
>
> hello,
>
> On Sun, Mar 30, 2025 at 10:41:59AM -0400, D. Ben Knoble wrote:
> > > Aside: that's why my ~/.vimrc looks like this so I can
> > > easily spot the problematic parts:
> >
> > I also frequently point folks towards [How to debug my
> > vimrc](https://vi.stackexchange.com/q/2003/10604) and [How to debug a
> > mapping](https://vi.stackexchange.com/q/7722/10604).
>
> thanks for this pointer. so sad those questions arise in stack* as we have a
> user mailing list.

I'm sorry to hear you feel that way; the goal of the StackExchange
project was to create a commons of high-quality resources (much like
Wikipedia has). I think the linked examples are good examples of this
(though if you visit the home page you will find more sand than pearls
these days, at the cost of having helped a great number of people).

Mailing lists are great, and they serve a different purpose for me
(cf. the recent extended discussion which might ultimately be boiled
down to a high-quality Q&A pair if desired).

Cheers,
Ben

--
--
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

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/vim_use/CALnO6CDagpG7ngx76ZczassNerxfdvx3FDkJhBXVk%2B2%2B8q1rYA%40mail.gmail.com.

Re: debuggable vimfiles



Den sön 30 mars 2025 21:53Marc Chantreux <mc@unistra.fr> skrev:
hello,

On Sun, Mar 30, 2025 at 10:41:59AM -0400, D. Ben Knoble wrote:
> > Aside: that's why my ~/.vimrc looks like this so I can
> > easily spot the problematic parts:
>
> I also frequently point folks towards [How to debug my
> vimrc](https://vi.stackexchange.com/q/2003/10604) and [How to debug a
> mapping](https://vi.stackexchange.com/q/7722/10604).

thanks for this pointer. so sad those questions arise in stack* as we have a
user mailing list.

I keep meaning to clean up my .vimrc my ~/.vim/after and my ~/.vim/autoload/bpj/, or at least comment them properly. In practice I just add everything at the bottom or near the top, depending on which works most like intended. The exception is my "text cleanup" function, the various commands which use that function and their config tables where I keep making those tables bigger and more numerous![1]

[1]: An uggly hack really: basically the function takes a possibly empty string of letters and a list of lists where each sublist has three items: an "id" letter which is uppercase for on by default and lowercase for off by default, a string with an ex statement — almost always an `%s///gce` of some complexity and a "description". For example

    ['I', '%s/\v⟮(\_.{-})⟯/_\1_/gce', '⟮...⟯ → _..._']
    or
    ['C', '%s/\v⌈(\_.{-})⌉/\L[\1]{.smallcaps}/gce', '⌈...⌉ → lc .smallcaps']
    or
    ['C', '%s/\v^\s*\zs%(local\s+)?_\s*=\s*\ze\[\=*\[/--/ce', 'void long string to comment']

    (Where ⟮⟯ is a pair of Unicode brackets. Don't ask what I need this for when I have Pandoc!)

    Each command passes its optional argument on to the function as the string of letters for turning an item on/off, whereafter the function executes each enabled item. A bit silly but beats typing all those substitutions every time. I try to keep the choice of letters mnemonic, but when all else files the function 'prints out' some or all lines of the table to a temporary buffer in a new window if it gets a non-empty third argument, which it does if the command was called with a bang. That's how I waste my time...


> > vim9script
> > run r/defaults.vim
> > run r/colors.vim
> >
> > run r/sublime.vim
> >         nnoremap <c-p> :SublimeCtrlP<cr>
> > run ftplugin/man.vim
> >         nnoremap <expr> K
> >         \ &kp == "man"   ? ":Man \<cword>\<cr>"
> >         \ : &kp == ":help" ? "K"
> >         \ : ":KP\<cr>"
> > run r/iab.vim
> > run r/ezfold.vim
> > run r/math.vim
> > run r/buffer_navigation.vim
> > run r/setvts.vim
> > run r/parentheses.vim
> > run r/cmd_makeprg.vim
> >         set aw ar
> >         nnoremap <c-s> :make!<cr>
> >         imap     <c-s> <c-o><c-s>
> > run r/mail-to.vim     | noremap <space>t :To<cr>
> > run r/was_fzy.vim
> > run r/dwm.vim
>
> What an interesting structure. Have you considered using
> `~/.vim/plugin` to have these load automatically?

this was the way I started back in the 90's because it was the
idiomatic way. also when packs came around, I had a most of the stuff
in ~/.vim/pack/*/start.

Nowadays, the only things I kepts in ~/.vim/pack/*/start are the
ftplugins and every addition comes as late as possible.

as example

┌─ /home/mc/.vim/after/ftplugin/python.vim ───
│ vim9script
│ set noet
│ packadd indent-object
│ run indent/python.vim
│ packadd lsp
│ call LspAddServer([{
│       name: 'python',
│       filetype: ['python'],
│       path: 'pylsp',
│       args: [],
│       syncInit: true,
│ }])
│
│ inoremap  <buffer> (fn def :<cr>……<cr>return ……<esc>2k$i
│ inoremap  <buffer> (wh while :<cr>……<esc>k$i
│ inoremap  <buffer> (wi with :<cr>……<esc>k$i
│ inoremap  <buffer> (aw async with :<cr>……<esc>k$i
│ inoremap  <buffer> (if if :<cr>……<esc>k$i
│ inoremap  <buffer> (ie if :<cr>……<cr>else:<cr>……<esc>3k$i
│ inoremap  <buffer> (fo for X in …… :<cr>……<esc>k^fXs
│ inoremap  <buffer> (af async for X in …… :<cr>……<esc>k^fXs
│

when I start to chase a bug, comment all the ~/.vimrc lines
and decomment it line by line.

in the process, I have

        inoremap <c-s>:w\|!tmux split vim /tmp/test<cr>

so I can easily see what changed.

regards

--
Marc Chantreux

--
--
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

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/vim_use/Z-mhAKeSOEEv9NQI%40prometheus.

--
--
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

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/vim_use/CADAJKhBcwFhLU8JEK%2BVUD%3DMfJ8W_VxFbAbqL%2BS5Ez5TY4hRhFA%40mail.gmail.com.

Sunday, March 30, 2025

debuggable vimfiles

hello,

On Sun, Mar 30, 2025 at 10:41:59AM -0400, D. Ben Knoble wrote:
> > Aside: that's why my ~/.vimrc looks like this so I can
> > easily spot the problematic parts:
>
> I also frequently point folks towards [How to debug my
> vimrc](https://vi.stackexchange.com/q/2003/10604) and [How to debug a
> mapping](https://vi.stackexchange.com/q/7722/10604).

thanks for this pointer. so sad those questions arise in stack* as we have a
user mailing list.

> > vim9script
> > run r/defaults.vim
> > run r/colors.vim
> >
> > run r/sublime.vim
> > nnoremap <c-p> :SublimeCtrlP<cr>
> > run ftplugin/man.vim
> > nnoremap <expr> K
> > \ &kp == "man" ? ":Man \<cword>\<cr>"
> > \ : &kp == ":help" ? "K"
> > \ : ":KP\<cr>"
> > run r/iab.vim
> > run r/ezfold.vim
> > run r/math.vim
> > run r/buffer_navigation.vim
> > run r/setvts.vim
> > run r/parentheses.vim
> > run r/cmd_makeprg.vim
> > set aw ar
> > nnoremap <c-s> :make!<cr>
> > imap <c-s> <c-o><c-s>
> > run r/mail-to.vim | noremap <space>t :To<cr>
> > run r/was_fzy.vim
> > run r/dwm.vim
>
> What an interesting structure. Have you considered using
> `~/.vim/plugin` to have these load automatically?

this was the way I started back in the 90's because it was the
idiomatic way. also when packs came around, I had a most of the stuff
in ~/.vim/pack/*/start.

Nowadays, the only things I kepts in ~/.vim/pack/*/start are the
ftplugins and every addition comes as late as possible.

as example

┌─ /home/mc/.vim/after/ftplugin/python.vim ───
│ vim9script
│ set noet
│ packadd indent-object
│ run indent/python.vim
│ packadd lsp
│ call LspAddServer([{
│ name: 'python',
│ filetype: ['python'],
│ path: 'pylsp',
│ args: [],
│ syncInit: true,
│ }])
│
│ inoremap <buffer> (fn def :<cr>……<cr>return ……<esc>2k$i
│ inoremap <buffer> (wh while :<cr>……<esc>k$i
│ inoremap <buffer> (wi with :<cr>……<esc>k$i
│ inoremap <buffer> (aw async with :<cr>……<esc>k$i
│ inoremap <buffer> (if if :<cr>……<esc>k$i
│ inoremap <buffer> (ie if :<cr>……<cr>else:<cr>……<esc>3k$i
│ inoremap <buffer> (fo for X in …… :<cr>……<esc>k^fXs
│ inoremap <buffer> (af async for X in …… :<cr>……<esc>k^fXs
│

when I start to chase a bug, comment all the ~/.vimrc lines
and decomment it line by line.

in the process, I have

inoremap <c-s>:w\|!tmux split vim /tmp/test<cr>

so I can easily see what changed.

regards

--
Marc Chantreux

--
--
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

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/vim_use/Z-mhAKeSOEEv9NQI%40prometheus.

Re: Vim Script for Python Developers guide updated with information about tuples

Hi,

On Sun, Mar 30, 2025 at 6:56 AM Steve Litt <slitt@troubleshooters.com> wrote:
Yegappan Lakshmanan said on Fri, 28 Mar 2025 23:34:27 -0700

>Hi all,
>
>I have updated the "Vim Script for Python Developers" guide with
>information about tuples:
>
>https://gist.github.com/yegappan/16d964a37ead0979b05e655aa036cad0
>
>Let me know if you have any comments or suggestions.

That's one heck of a resource! Does everything in that document work
with the Vim Script in Vim9?

I started working on the guide before the Vim9script support was developed.
So the guide applies to the classic Vimscript.  I need to find time to create a
similar guide for the Vim9script.

Regards,
Yegappan
 

Thanks,

SteveT

Steve Litt

http://444domains.com


--
--
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

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/vim_use/CAAW7x7mkedmzaOqoEbZDzFK-zq2%2BFuWphUBErqy0X63cmrnnXA%40mail.gmail.com.

Re: inoremap and typing pace?

On Sun, Mar 30, 2025 at 3:05 AM Marc Chantreux <mc@unistra.fr> wrote:
>
> Aside: that's why my ~/.vimrc looks like this so I can
> easily spot the problematic parts:

I also frequently point folks towards [How to debug my
vimrc](https://vi.stackexchange.com/q/2003/10604) and [How to debug a
mapping](https://vi.stackexchange.com/q/7722/10604).

> vim9script
> run r/defaults.vim
> run r/colors.vim
>
> run r/sublime.vim
> nnoremap <c-p> :SublimeCtrlP<cr>
> run ftplugin/man.vim
> nnoremap <expr> K
> \ &kp == "man" ? ":Man \<cword>\<cr>"
> \ : &kp == ":help" ? "K"
> \ : ":KP\<cr>"
> run r/iab.vim
> run r/ezfold.vim
> run r/math.vim
> run r/buffer_navigation.vim
> run r/setvts.vim
> run r/parentheses.vim
> run r/cmd_makeprg.vim
> set aw ar
> nnoremap <c-s> :make!<cr>
> imap <c-s> <c-o><c-s>
> run r/mail-to.vim | noremap <space>t :To<cr>
> run r/was_fzy.vim
> run r/dwm.vim

What an interesting structure. Have you considered using
`~/.vim/plugin` to have these load automatically? (You could control
the order using sorted names, I believe.)

--
D. Ben Knoble

--
--
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

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/vim_use/CALnO6CASwQcK-th8YueFkbHgppuwYtY1PhWy1oR0cAx_k_PEfw%40mail.gmail.com.