diff options
author | Bram Moolenaar <Bram@vim.org> | 2005-05-22 22:07:59 +0000 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2005-05-22 22:07:59 +0000 |
commit | 2389c3c6402fedaa5b198a7bed04daabc2939e7b (patch) | |
tree | 95fe4bdbc76feb3fb1b4b599138796c86b38cde1 /runtime/doc/change.txt | |
parent | 0d40699d6defaf6f0d308c2d96ae885b013ad8db (diff) |
updated for version 7.0075
Diffstat (limited to 'runtime/doc/change.txt')
-rw-r--r-- | runtime/doc/change.txt | 32 |
1 files changed, 31 insertions, 1 deletions
diff --git a/runtime/doc/change.txt b/runtime/doc/change.txt index 85271b1c20..0164054281 100644 --- a/runtime/doc/change.txt +++ b/runtime/doc/change.txt @@ -1,4 +1,4 @@ -*change.txt* For Vim version 7.0aa. Last change: 2005 Apr 26 +*change.txt* For Vim version 7.0aa. Last change: 2005 May 22 VIM REFERENCE MANUAL by Bram Moolenaar @@ -19,6 +19,7 @@ commands with the "." command. 4.4 Changing tabs |change-tabs| 5. Copying and moving text |copy-move| 6. Formatting text |formatting| +7. Sorting text |sorting| For inserting text see |insert.txt|. @@ -1479,5 +1480,34 @@ And a few warnings: - Formatting a long paragraph and/or with complicated indenting may be slow. +============================================================================== +7. Sorting text *sorting* + +Vim has a sorting function and a sorting command. The sorting function can be +found here: |sort()|. + + *:sor* *:sort* +:[range]sor[t][!] [i] [u] [/{pattern}/] + Sort lines in [range]. + + With [!] the order is reversed. + + With [i] case is ignored. + + With [u] only keep the first of a sequence of + identical lines (ignoring case when [i] is used). + + When /{pattern}/ is specified the text matched with + {pattern} is skipped, so that you sort on what comes + after the match. For lines without a match sorting + starts in the first column (e.g., for empty lines). + Instead of the slash any non-letter can be used. + For example, to sort on the second comma-separated + field: > + :sort /[^,]*,/ +< To sort on the text at virtual column 10 (thus + ignoring the difference between tabs and spaces): > + :sort /.*\%10v/ +< vim:tw=78:ts=8:ft=help:norl: |