aboutsummaryrefslogtreecommitdiff
path: root/runtime/doc/change.txt
diff options
context:
space:
mode:
authorJan Edmund Lazo <jan.lazo@mail.utoronto.ca>2021-05-09 17:08:21 -0400
committerGitHub <noreply@github.com>2021-05-09 17:08:21 -0400
commitd2be261e8d1bcf165346255ae701564a5f62bf7d (patch)
tree470c5fb8f4e57098295e87f0df318f729569dd83 /runtime/doc/change.txt
parentf8173df4d7ecec239629921736340d3f4d1dcfd4 (diff)
parenteef5a627bfc4341fdd6f12ea5932d11b12fbf2c0 (diff)
downloadrneovim-d2be261e8d1bcf165346255ae701564a5f62bf7d.tar.gz
rneovim-d2be261e8d1bcf165346255ae701564a5f62bf7d.tar.bz2
rneovim-d2be261e8d1bcf165346255ae701564a5f62bf7d.zip
Merge pull request #14403 from seandewar/vim-8.2.1933
vim-patch:8.2.{0174,1933,1935,1946,2286,2287}
Diffstat (limited to 'runtime/doc/change.txt')
-rw-r--r--runtime/doc/change.txt15
1 files changed, 12 insertions, 3 deletions
diff --git a/runtime/doc/change.txt b/runtime/doc/change.txt
index 19a8be1102..b2e910a834 100644
--- a/runtime/doc/change.txt
+++ b/runtime/doc/change.txt
@@ -1771,7 +1771,7 @@ Vim has a sorting function and a sorting command. The sorting function can be
found here: |sort()|, |uniq()|.
*:sor* *:sort*
-:[range]sor[t][!] [b][f][i][n][o][r][u][x] [/{pattern}/]
+:[range]sor[t][!] [b][f][i][l][n][o][r][u][x] [/{pattern}/]
Sort lines in [range]. When no range is given all
lines are sorted.
@@ -1779,6 +1779,16 @@ found here: |sort()|, |uniq()|.
With [i] case is ignored.
+ With [l] sort uses the current collation locale.
+ Implementation details: strcoll() is used to compare
+ strings. See |:language| to check or set the collation
+ locale. Example: >
+ :language collate en_US.UTF-8
+ :%sort l
+< |v:collate| can also used to check the current locale.
+ Sorting using the locale typically ignores case.
+ This does not work properly on Mac.
+
Options [n][f][x][o][b] are mutually exclusive.
With [n] sorting is done on the first decimal number
@@ -1847,8 +1857,7 @@ found here: |sort()|, |uniq()|.
Note that using `:sort` with `:global` doesn't sort the matching lines, it's
quite useless.
-The details about sorting depend on the library function used. There is no
-guarantee that sorting obeys the current locale. You will have to try it out.
+`:sort` does not use the current locale unless the l flag is used.
Vim does do a "stable" sort.
The sorting can be interrupted, but if you interrupt it too late in the