Wednesday, December 31, 2025

Re: Q&A: MSDOS SET command gave me some of my mapped commands

One last message. Plus zero did not work. Yes, it is acting as if it
were octal. Vim should not really do that as sometimes people do put
zeros in front of the number. (At least, this old fogey remembers when
people used to do that all of the time.) Here is what works:

str2nr( $value, $type )

So I used str2nr( $ext, 10 )

And that forced it to keep the number as 10. Just thinking aloud here
but it would be nice to have 0b for binary, 0c for octal, 0x for
hexadecimal, and 0d for decimal. But I guess no one wants to do that.
:-)

Mark

On Wed, Dec 31, 2025 at 7:42 AM Mark Manning
<mark.eugene.manning@gmail.com> wrote:
>
> Ugh. Should have thought of that. I thought up a solution wfile I slept. Number gotten off of a filenamfe. So a plus zero when I get it should work Thanks again.
>
> Mark
>
>
> On Wed, Dec 31, 2025, 4:31 AM Christian Brabandt <cblists@256bit.org> wrote:
>>
>>
>> On Mi, 31 Dez 2025, Mark Manning wrote:
>>
>> > Hi again Christian!
>> >
>> > I am back with another wierdo problem.
>> >
>> > Here is the code:
>> >
>> > "
>> > " Make a new filename (ie: full file name PLUS .(high_num+1)
>> > " In other words - make a new filename with the backup number one
>> > " higher than the highest backup number. Example A.BOB;00001
>> > "
>> > echo "High_num = " . high_num
>> > let high_num = high_num + 1
>> > echo "High_num = " . high_num
>> > let ext = printf("%05d", high_num )
>> > echo "High_num = " . high_num
>> > echo "ext = " . ext
>> > let new_path = expand("%:p") . ";" . ext
>> > "
>> > " Now save the file to the new file name we just made.
>> > "
>> > echo "new_path = " . new_path
>> >
>> > And here is the output (I haven't included all of the output - only
>> > from this point).
>> >
>> > High_num = 00010
>> > High_num = 9
>> > High_num = 9
>> > ext = 00009
>> > new_path = D:\My Programs\PHP\Fix Paper Types\fixpapers.
>> > php;00009
>> >
>> > As you can see, "High_num" is originally set to "00010". (Actual
>> > variable name is "high_num".) Anyway, I add one to that number and Vim
>> > changes the number to "9". I have tried using:
>> >
>> > let high_num += 1
>> > and
>> > let ++high_num <---Got an error doing this
>> > and
>> > let high_num++ <---Got an error doing this too
>> > and
>> > let high_num = high_num + 1
>> >
>> > and I just keep getting that high_num has decremented by one. I'm using
>> > version 9.1. Should I upgrade to a higher version of Vim? Thanks ahead
>> > of time for responsing. I is after 2:00am here so I've got to go to
>> > bed. Been working on this all day trying anything I could think of.
>> >
>> > Mark
>> > PS: If you want the source code I can zip it up and send it. Simple
>> > script called decvers.vim. (DEC VERSion - probably should rename it
>> > to something like Upgrade_version.vim or maybe Make_backup.vim. I'm
>> > basing it on the old DEC 11/780 system where every time you edited a
>> > file it made a backup of the file and add the next higher number
>> > to the end as ";#####". Earlier version numbers are older
>> > than the bigger version numbers.)
>>
>> You can include the script verbose on the list, don't need to send it to
>> me. So the whole list audience has a chance to chime in.
>>
>> My guess is the value is seen as octal, and therefore Vim is increments
>> it in octal mode (00010 -> 8 decimal).
>>
>> Instead of incrementing a string value, I'd recommend to perform the
>> actual arithmetics using a decimal number and then use printf() to
>> convert it into a string value.
>>
>> Thanks,
>> Christian
>> --
>> The people rule.
>>
>> --
>> --
>> 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 a topic in the Google Groups "vim_use" group.
>> To unsubscribe from this topic, visit https://groups.google.com/d/topic/vim_use/VAd-XX1KMOU/unsubscribe.
>> To unsubscribe from this group and all its topics, send an email to vim_use+unsubscribe@googlegroups.com.
>> To view this discussion visit https://groups.google.com/d/msgid/vim_use/aVT7N2dFqNeLPaAr%40256bit.org.

--
--
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/CAPJLamywWdB8hpOr_zi3x%3DYuL1efULZ_g3jSunxMsvvDELCnpg%40mail.gmail.com.

Re: Q&A: MSDOS SET command gave me some of my mapped commands

Ugh.  Should have thought of that. I thought up a solution wfile I slept. Number gotten off of a filenamfe. So a plus zero when I get it should work   Thanks again. 

Mark


On Wed, Dec 31, 2025, 4:31 AM Christian Brabandt <cblists@256bit.org> wrote:

On Mi, 31 Dez 2025, Mark Manning wrote:

> Hi again Christian!
>
> I am back with another wierdo problem.
>
> Here is the code:
>
> "     
> " Make a new filename (ie: full file name PLUS .(high_num+1)
> " In other words - make a new filename with the backup number one
> " higher than the highest backup number. Example A.BOB;00001
> "
>       echo "High_num = " . high_num
>       let high_num = high_num + 1
>       echo "High_num = " . high_num
>       let ext = printf("%05d", high_num )
>       echo "High_num = " . high_num
>       echo "ext = " . ext
>       let new_path = expand("%:p") . ";" . ext
> "     
> "             Now save the file to the new file name we just made.
> "     
>       echo "new_path = " . new_path
>
> And here is the output (I haven't included all of the output - only
> from this point).
>
> High_num = 00010
> High_num = 9
> High_num = 9
> ext = 00009
> new_path = D:\My Programs\PHP\Fix Paper Types\fixpapers.
> php;00009
>
> As you can see, "High_num" is originally set to "00010". (Actual
> variable name is "high_num".) Anyway, I add one to that number and Vim
> changes the number to "9". I have tried using:
>
>       let high_num += 1
> and
>       let ++high_num  <---Got an error doing this
> and
>       let high_num++  <---Got an error doing this too
> and
>       let high_num = high_num + 1
>
> and I just keep getting that high_num has decremented by one. I'm using
> version 9.1. Should I upgrade to a higher version of Vim? Thanks ahead
> of time for responsing. I is after 2:00am here so I've got to go to
> bed. Been working on this all day trying anything I could think of.
>
> Mark
> PS: If you want the source code I can zip it up and send it. Simple
> script called decvers.vim. (DEC VERSion - probably should rename it
> to something like Upgrade_version.vim or maybe Make_backup.vim. I'm
> basing it on the old DEC 11/780 system where every time you edited a
> file it made a backup of the file and add the next higher number
> to the end as ";#####". Earlier version numbers are older
> than the bigger version numbers.)

You can include the script verbose on the list, don't need to send it to
me. So the whole list audience has a chance to chime in.

My guess is the value is seen as octal, and therefore Vim is increments
it in octal mode (00010 -> 8 decimal).

Instead of incrementing a string value, I'd recommend to perform the
actual arithmetics using a decimal number and then use printf() to
convert it into a string value.

Thanks,
Christian
--
The people rule.

--
--
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 a topic in the Google Groups "vim_use" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/vim_use/VAd-XX1KMOU/unsubscribe.
To unsubscribe from this group and all its topics, send an email to vim_use+unsubscribe@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/vim_use/aVT7N2dFqNeLPaAr%40256bit.org.

--
--
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/CAPJLamyekZagPxLQ5Su2TGBNKehe2%3DwGapn%3DpjxFncVxWS7Fsw%40mail.gmail.com.

Releasing Vim 9.2

Hello everybody,

After close to 2 years and more than 2000 numbered patches, including
new features, bug fixes, and security updates, we have reached a state
where we should release a new minor version: Vim 9.2.

If you want to know what changed since the release of Vim 9.1, please
have a look at :h version-9.2 Note that this is only fully comprehensive
in the latest patch levels. It is also available online here:
https://github.com/vim/vim/blob/master/runtime/doc/version9.txt#L41542)

Thanks to everyone who has contributed to improving Vim! It's hard to
believe that 2 years have already passed since the 9.1 release.

I'd like to use the next 6 weeks (until around mid February) as the
stabilization period, followed by the release of Vim 9.2.

During this time, only runtime file updates, translations, security
fixes and clear bug fixes will be merged to make the release as stable
as possible (without introducing new issues obviously).

Now is also a good time for anyone using an older version of Vim to test
it, so we have a chance to fix any remaining issues.

If you are a maintainer of any runtime file or a translator, please
consider creating a PR for the Vim main tree. There have been quite a
few new error messages added, so please ensure that your scripts and
translations are up to date.

Thanks
Chris
--
Letzte Worte eines Chemikers:
"*H* steht für Stickstoff - und das brennt *nicht*."

--
--
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/aVUBdrDC1T90OsvN%40256bit.org.

Re: Q&A: MSDOS SET command gave me some of my mapped commands

On Mi, 31 Dez 2025, Mark Manning wrote:

> Hi again Christian!
>
> I am back with another wierdo problem.
>
> Here is the code:
>
> "
> " Make a new filename (ie: full file name PLUS .(high_num+1)
> " In other words - make a new filename with the backup number one
> " higher than the highest backup number. Example A.BOB;00001
> "
> echo "High_num = " . high_num
> let high_num = high_num + 1
> echo "High_num = " . high_num
> let ext = printf("%05d", high_num )
> echo "High_num = " . high_num
> echo "ext = " . ext
> let new_path = expand("%:p") . ";" . ext
> "
> " Now save the file to the new file name we just made.
> "
> echo "new_path = " . new_path
>
> And here is the output (I haven't included all of the output - only
> from this point).
>
> High_num = 00010
> High_num = 9
> High_num = 9
> ext = 00009
> new_path = D:\My Programs\PHP\Fix Paper Types\fixpapers.
> php;00009
>
> As you can see, "High_num" is originally set to "00010". (Actual
> variable name is "high_num".) Anyway, I add one to that number and Vim
> changes the number to "9". I have tried using:
>
> let high_num += 1
> and
> let ++high_num <---Got an error doing this
> and
> let high_num++ <---Got an error doing this too
> and
> let high_num = high_num + 1
>
> and I just keep getting that high_num has decremented by one. I'm using
> version 9.1. Should I upgrade to a higher version of Vim? Thanks ahead
> of time for responsing. I is after 2:00am here so I've got to go to
> bed. Been working on this all day trying anything I could think of.
>
> Mark
> PS: If you want the source code I can zip it up and send it. Simple
> script called decvers.vim. (DEC VERSion - probably should rename it
> to something like Upgrade_version.vim or maybe Make_backup.vim. I'm
> basing it on the old DEC 11/780 system where every time you edited a
> file it made a backup of the file and add the next higher number
> to the end as ";#####". Earlier version numbers are older
> than the bigger version numbers.)

You can include the script verbose on the list, don't need to send it to
me. So the whole list audience has a chance to chime in.

My guess is the value is seen as octal, and therefore Vim is increments
it in octal mode (00010 -> 8 decimal).

Instead of incrementing a string value, I'd recommend to perform the
actual arithmetics using a decimal number and then use printf() to
convert it into a string value.

Thanks,
Christian
--
The people rule.

--
--
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/aVT7N2dFqNeLPaAr%40256bit.org.

Re: Q&A: MSDOS SET command gave me some of my mapped commands

Hi again Christian!

I am back with another wierdo problem.

Here is the code:

"
" Make a new filename (ie: full file name PLUS .(high_num+1)
" In other words - make a new filename with the backup number one
" higher than the highest backup number. Example A.BOB;00001
"
echo "High_num = " . high_num
let high_num = high_num + 1
echo "High_num = " . high_num
let ext = printf("%05d", high_num )
echo "High_num = " . high_num
echo "ext = " . ext
let new_path = expand("%:p") . ";" . ext
"
" Now save the file to the new file name we just made.
"
echo "new_path = " . new_path

And here is the output (I haven't included all of the output - only
from this point).

High_num = 00010
High_num = 9
High_num = 9
ext = 00009
new_path = D:\My Programs\PHP\Fix Paper Types\fixpapers.
php;00009

As you can see, "High_num" is originally set to "00010". (Actual
variable name is "high_num".) Anyway, I add one to that number and Vim
changes the number to "9". I have tried using:

let high_num += 1
and
let ++high_num <---Got an error doing this
and
let high_num++ <---Got an error doing this too
and
let high_num = high_num + 1

and I just keep getting that high_num has decremented by one. I'm using
version 9.1. Should I upgrade to a higher version of Vim? Thanks ahead
of time for responsing. I is after 2:00am here so I've got to go to
bed. Been working on this all day trying anything I could think of.

Mark
PS: If you want the source code I can zip it up and send it. Simple
script called decvers.vim. (DEC VERSion - probably should rename it
to something like Upgrade_version.vim or maybe Make_backup.vim. I'm
basing it on the old DEC 11/780 system where every time you edited a
file it made a backup of the file and add the next higher number
to the end as ";#####". Earlier version numbers are older
than the bigger version numbers.)

--
--
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/20251231030048.77b3b891e0b09c39b0bbbd9f%40gmail.com.

Tuesday, December 30, 2025

Cannot get HTML here-doc syntax to work in Perl file using Vim 7

Using Vim 7.4, with the following Perl code: 

print <<"HTML"; 
<table> 
   <tr> 
     <td>I AM THE TABLE.</td> 
   </tr> 
</table> 
HTML 

 ...I want the syntax highlighting to display as HTML. I tried adding the following code to ~/.vim/after/syntax/perl.vim:

" Load HTML syntax
syntax include @html syntax/html.vim

" Highlight HTML inside <<HTML heredocs
syntax region perlHereDocHTML
      \ matchgroup=perlHereDocDelimiter
      \ start=+<<\s*["']\=HTML["']\=+
      \ end=+^HTML$+
      \ contains=@html
      \ keepend

But it is still not working. It is displayed as plain yellow text. How do I get it to highlight the HTML elements as if I were viewing a .html file?

--
--
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/ebd8e648-f223-4dbc-b3cb-a50320a9b634n%40googlegroups.com.

Friday, December 19, 2025

Re: Bug with shell command !{cmd} using cmd.exe

>
> I still would like to know why this happens in Windows 11 (I do consider
> this a bug because I should not have to include current directory in
> path).
>

Ask Microsoft; their "innovation" broke something that previously
worked.,which is not wholly unprecedented.

--
--
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/446f6651934f765ba07703f5d77ee382.squirrel%40webmail.vybenetworks.com.