mirror of
https://github.com/Kitware/CMake.git
synced 2026-02-21 14:40:26 -06:00
Merge topic 'list_sort'
49a51a61d7 list: Add options to control the SORT comparison operation
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2065
This commit is contained in:
@@ -28,7 +28,7 @@ Synopsis
|
||||
|
||||
`Ordering`_
|
||||
list(`REVERSE`_ <list>)
|
||||
list(`SORT`_ <list>)
|
||||
list(`SORT`_ <list> [...])
|
||||
|
||||
Introduction
|
||||
^^^^^^^^^^^^
|
||||
@@ -253,7 +253,23 @@ Reverses the contents of the list in-place.
|
||||
|
||||
::
|
||||
|
||||
list(SORT <list>)
|
||||
|
||||
list(SORT <list> [COMPARE <compare>] [CASE <case>] [ORDER <order>])
|
||||
|
||||
Sorts the list in-place alphabetically.
|
||||
Use the option ``<compare>`` to select the compare type for sorting.
|
||||
The ``<compare>`` option may be one of:
|
||||
|
||||
* ``STRING``: Sorts a list of strings alphabetically.
|
||||
* ``FILE_BASENAME``: Sort a list of pathnames of files by their basenames.
|
||||
|
||||
Use the option ``<case>`` to select a case sensitive or case insensitive sort mode.
|
||||
The ``<case>`` option may be one of:
|
||||
|
||||
* ``SENSITIVE``: Sorts the list alphabetically.
|
||||
* ``INSENSITIVE``: Sorts the list alphabetically in descending order.
|
||||
|
||||
Use the option ``<order>`` to select a case sensitive or case insensitive sort mode.
|
||||
The ``<order>`` option may be one of:
|
||||
|
||||
* ``ASCENDING``: Sorts the list in ascending order.
|
||||
* ``DESCENDING``: Sorts the list in descending order.
|
||||
|
||||
Reference in New Issue
Block a user