FG

Why does vim increment (Ctrl+A) skip 8s and 9s?

Fresh3 days ago
Mar 15, 20261045 views
Confidence Score0%
0%

Problem

I'm trying to write a long XML catalog using vim macros to write all the repetitive stuff. I've found it's useful to write a macro yanking the previous entry, then going through each item and incrementing it with Ctrl+A. Vim does OK with incrementing 001 to 002, all the way through 007, but then it…

Unverified for your environment

Select your OS to check compatibility.

1 Fix

Canonical Fix
Unverified Fix
New Fix – Awaiting Verification

Fix for: Why does vim increment (Ctrl+A) skip 8s and 9s?

Low Risk

will handle it. The problem you're having is because Vim considers numbers starting with 0 octal or hex, depending. More on that in

Awaiting Verification

Be the first to verify this fix

Sign in to verify this fix

Environment