diff options
author | wiz <wiz> | 2016-11-30 14:38:58 +0000 |
---|---|---|
committer | wiz <wiz> | 2016-11-30 14:38:58 +0000 |
commit | e41277251678f0045f8c58cac7eb4bbb7aa797d0 (patch) | |
tree | d2161a48a66de9b28f94ee165145bb48f6a3522d /textproc/py-natsort/DESCR | |
parent | 9284263e67d40cd01e0eda7ac092987e6761286f (diff) | |
download | pkgsrc-e41277251678f0045f8c58cac7eb4bbb7aa797d0.tar.gz |
Clean up pkglint. Add some test dependencies, 4 more are not packaged
yet.
Diffstat (limited to 'textproc/py-natsort/DESCR')
-rw-r--r-- | textproc/py-natsort/DESCR | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/textproc/py-natsort/DESCR b/textproc/py-natsort/DESCR index 9eef59e1409..56aa10e56d3 100644 --- a/textproc/py-natsort/DESCR +++ b/textproc/py-natsort/DESCR @@ -6,12 +6,12 @@ not get the results that you expect: >>> sorted(a) ['a1', 'a10', 'a2', 'a4', 'a9'] -Notice that it has the order (‘1’, ‘10’, ‘2’) - this is because the +Notice that it has the order ('1', '10', '2') - this is because the list is being sorted in lexicographical order, which sorts numbers -like you would letters (i.e. ‘b’, ‘ba’, ‘c’). +like you would letters (i.e. 'b', 'ba', 'c'). natsort provides a function natsorted that helps sort lists -“naturally”, either as real numbers (i.e. signed/unsigned floats +"naturally", either as real numbers (i.e. signed/unsigned floats or ints), or as versions. Using natsorted is simple: >>> from natsort import natsorted @@ -20,6 +20,4 @@ or ints), or as versions. Using natsorted is simple: ['a1', 'a2', 'a4', 'a9', 'a10'] natsorted identifies numbers anywhere in a string and sorts them -naturally. Here are some other things you can do with natsort (please -see the examples for a quick start guide, or the api for more -details). +naturally. |