Vim Recall繁體中文

Save buffer if modified

:update

Example

Normal 0 / 2

Save buffer if modified.

Example files

alpha.txt
alpha one ↩ alpha two ↩ alpha three
Before & after

Before

Example files

alpha.txt
alpha one ↩ alpha two ↩ alpha three

After

Example files

alpha.txt
changed alpha ↩ alpha two ↩ alpha three

Start in Normal mode. Saving writes only this example's temporary files. The Files panel shows the actual saved text.

Details & Vim help

Example replayed in Vim

Save buffer if modified. 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 :up[date] 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.