Tuesday, September 6, 2022

Print the first field of a table in one line separated by commas


I have the table:

1001 John Sena 40000
1002 Jafar Iqbal   60000
1003 Meher Nigar   30000
1004 Jonny Liver   70000

I'd like to print the first field, preceded by xx, and followed by yyy,
separated by commas, as in:

xx1001yyy, xx1002yyy, xx1003yyy, xx1004yyy

And I'd like to get this output after the table. I think I can do it with awk, but I'd like to do it with vim, if it is possible

-- 
Cesar

--
--
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 on the web visit https://groups.google.com/d/msgid/vim_use/64256999-0bf6-41d5-bd94-9ef51bf4145cn%40googlegroups.com.

Re: Gvim message on XDG textedit URL link

Andrew Bernard wrote:
> I have PDF's with links in them and XDG textedit URLs that can take me
> from the PDF to the source file (for lilypond music engraving if
> interested)., The links work and take me to the right line and column
> corresponding to the link in the PDF. But I am unable to turn off the
> lengthy and needless long cryptic message displayed at the bottom of
> the screen despite searching for answers. Having to see this and press
> enter every time is tedious. This is an example:
>
> gvim message.jpg
>
> Here's the sort of textedit link:
>
> textedit:///home/acb/work/test.ly:4:2:3
>
> What should one do?
>
I am unable to find a "textedit:" string in any of the vim runtime
files. Sounds like you've installed a plugin to handle textedit links --
so I suggest finding out what the plugin name is and contacting its author.

Chip Campbell

--
--
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 on the web visit https://groups.google.com/d/msgid/vim_use/d4f26911-123e-a70f-6bad-efc5733394b0%40drchip.org.

Monday, September 5, 2022

Long Vim start time after upgrading Debian

Hi,

After upgrading my Debian system from buster to bullseye (Vim 8.1 to
8.2), I'm seeing a noticeably longer start time for Vim, about 5-6
seconds. I tried:

vim --startuptime vim.log

and looking at that vim.log file it seems sourcing the syntax.vim file
is what's taking unusually long:

...
050.939 001.488 000.145: sourcing /usr/share/vim/vim82/syntax/synload.vim
050.969 001.925 000.184: sourcing /usr/share/vim/vim82/syntax/syntax.vim
5275.196 5255.470 5241.109: sourcing $HOME/.vimrc
5275.233 000.122: sourcing vimrc file(s)
...

Not sure what changed in upgrading my Debian OS that could've caused
this added startup time... any clues or suggestions much appreciated.

Thanks,

John

--
John Magolske
http://b79.net/contact

--
--
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 on the web visit https://groups.google.com/d/msgid/vim_use/YxZmw72FocVIHvAs%40s70206.gridserver.com.

Gvim message on XDG textedit URL link

I have PDF's with links in them and XDG textedit URLs that can take me from the PDF to the source file (for lilypond music engraving if interested)., The links work and take me to the right line and column corresponding to the link in the PDF. But I am unable to turn off the lengthy and needless long cryptic message displayed at the bottom of the screen despite searching for answers. Having to see this and press enter every time is tedious. This is an example:

gvim message.jpg

Here's the sort of textedit link:

textedit:///home/acb/work/test.ly:4:2:3

What should one do?


--
--
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 on the web visit https://groups.google.com/d/msgid/vim_use/7af9a83f-8d5b-482d-9fee-123d092a90c5n%40googlegroups.com.

Sunday, September 4, 2022

Re: yanking works sometimes, and sometimes not

On Tue, Aug 23, 2022 at 04:31:49AM -0700, Igor Lerinc wrote:
>- I dont know if this is to terminal emulator i'm using (xcfe4 terminal),
>but often, when i want to copy to external programs, i have set up
>shortcut, <Leader>y to be as "+y , so it copy external, but when i try to
>combine it with <motions>, it doesn't detect.
>It is copying inside vim, that works, but stagnates for other programs,
>doesn't copy it.
>
>It works when i do via visual mode, but that is so ineffective, i don't
>want to use visual mode.
>
>When i do it via visual mode, suddenly, it again responds to combining
><Leader>y with <motions>
>
>I have both "+y and "*y for this shortcut, it works, but, sometimes is
>unresponsive, i don't know if xcfe4 terminal do some sort of suspending,
>and that's why it doesn't register itself.

Maybe having "unnamedplus" in 'clipboard' is useful to you. See :help clipboard-unnamedplus

--
--
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 on the web visit https://groups.google.com/d/msgid/vim_use/YxUHGPa1hkUg4uyS%40rainslide.net.

Friday, September 2, 2022

Re: Announce: LitREPL plugin for literate programming

Hi Nikolas!

Somehow, Codi.vim escaped from my attention, thanks for letting me know. At first glance, I would name the following differences:
- Codi.vim seems to work on a line-by-line basis. As far as I see, it doesn't attempt to guess the structure of the document. LitREPL (in theory) works with valid Markdown/Latex documents. It uses its own express-parsers to find out the location of multi-line code/result sections, and transforms the document accordingly, making it possible to emulate a WYSIWY(with a little delay)G.
- Codi.vim doesn't seem to preserve the state of the interpreter between editing sessions. LitREPL, in contrast, keeps the interpreter running with its stdin/stdout connected to pipes which are pinned as files in the filesystem. It is also possible to get direct access to the interpreter's shell. As a possible downside, LitREPL depends on certain Posix tools to make things work.
- Codi.vim is implemented mostly in Vimscript, while LitREPL depends only on a small Vim-script wrapper while most of the work is done by a command line application written in Python. Probably, porting LitREPL to other editors should be an easier task.
- There are probably other minor differences like the support of ASCII '\r' symbol required for libraries like tqdm of Python (I see the support of Preprocessors in Codi.vim, so may be it does have the required support), the status of Ctrl+C support (LitREPL should support breaking the infinite loop), other behaviour on long-running commands (I plan to support the incremental output in LitREPL via files), etc.

BR,
Sergei



пт, 2 сент. 2022 г. в 14:11, N V <nivaemail@gmail.com>:
Hi Sergei, 

Do you know codi.vim ? 

What's the main difference with your plugin ? 
Thank you
Nicolas 

Le jeudi 25 août 2022 à 13:43:07 UTC+2, grr...@gmail.com a écrit :
Hello. I'm glad to announce a (yet another) plugin for literate programming, for now in Python. Briefly, it aims to get a Jupyter-notebook look-and-feel while editing Markdown or Latex documents in Vim.


The plugin detects code/result blocks, pipes their content through the persistently running interpreter and pastes the result back into the file. Python and IPython are currently supported, other languages don't seem to be a problem.

Currently, the plugin comes with an application of nearly 500 lines of code and takes less than 100 lines of code itself at the cost of being dependent on Posix APIs like pipes or shell utils.

The project is less than a month old, some troubles are possible. Brave testers are welcome, as well as comments.

BR,
Sergei

--
--
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 on the web visit https://groups.google.com/d/msgid/vim_use/bc99067a-71d0-44b3-bc8e-72bb5af21893n%40googlegroups.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 on the web visit https://groups.google.com/d/msgid/vim_use/CAMOkk_YxNh6e82mrukpfgo78iftvUfgr3e2BdJdbsrkcAnmYRg%40mail.gmail.com.

Re: Announce: LitREPL plugin for literate programming

Hi Sergei, 

Do you know codi.vim ? 
https://github.com/metakirby5/codi.vim

What's the main difference with your plugin ? 
Thank you
Nicolas 

Le jeudi 25 août 2022 à 13:43:07 UTC+2, grr...@gmail.com a écrit :
Hello. I'm glad to announce a (yet another) plugin for literate programming, for now in Python. Briefly, it aims to get a Jupyter-notebook look-and-feel while editing Markdown or Latex documents in Vim.


The plugin detects code/result blocks, pipes their content through the persistently running interpreter and pastes the result back into the file. Python and IPython are currently supported, other languages don't seem to be a problem.

Currently, the plugin comes with an application of nearly 500 lines of code and takes less than 100 lines of code itself at the cost of being dependent on Posix APIs like pipes or shell utils.

The project is less than a month old, some troubles are possible. Brave testers are welcome, as well as comments.

BR,
Sergei

--
--
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 on the web visit https://groups.google.com/d/msgid/vim_use/bc99067a-71d0-44b3-bc8e-72bb5af21893n%40googlegroups.com.