Save undo information to a file
Example
Normal 0 / 2Command-line 1 / 2Normal 2 / 2Save undo information to a file.
Undo fixture
- notes.undo
absent
Undo history
- Current text
blue- Available undo
red
Command entered · ready to apply
Undo fixture
- notes.undo
absent
Undo history
- Current text
blue- Available undo
red
Saves the existing red → blue undo history to notes.undo; buffer text is unchanged.
Undo fixture
- notes.undo
saved undo history for blue: undo restores red
Undo history
- Current text
blue- Available undo
red
Before & after
Before
Undo fixture
- notes.undo
absent
Undo history
- Current text
blue- Available undo
red
After
Undo fixture
- notes.undo
saved undo history for blue: undo restores red
Undo history
- Current text
blue- Available undo
red
Subject: :wundo. Documentation-backed illustration; assumes +persistent_undo and writable absent file; not replay-verified. Saves the existing red → blue undo history to notes.undo; buffer text is unchanged.
blueCursor on line 1, column 1Details & Vim help
Save undo information to a file. This Ex reference uses the full command name; the alphabetical index omits arguments. Supply the ranges, arguments, flags and prerequisite state documented in the linked help. Press Enter to submit a complete command. The index spelling :wu[ndo] puts the optional abbreviation suffix in square brackets; those brackets are not typed. Availability and exact behavior can depend on Vim build features, options, mappings and editor state; the linked help is authoritative.