Skip to content

Commit e60d686

Browse files
authored
Readme examples (#11)
* adding usage gif. * bump version. * Trying to clarify usage in readme.
1 parent b3dde13 commit e60d686

File tree

4 files changed

+95
-7
lines changed

4 files changed

+95
-7
lines changed

README.md

Lines changed: 46 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,51 @@ Extension for nova.app that allows you to perform simple sorting on highlighted
1111

1212
Currently you can sort in 4 different ways:
1313

14-
- Sort multiple lines based on a regular 0-9a-z sort.
15-
- Sort one or more lines internally. For example a line containing `cba` will become `abc`.
14+
- Sort multiple lines alphanumerically.
15+
- Sort content of one or more lines. For example a line containing `cba` will become `abc`.
1616
- Sort multiple lines based on length (the number of characters including whitespace).
1717
- Sort multiple lines based on length but reversed.
18+
19+
# Examples
20+
21+
```js
22+
// 1. Sort inline
23+
cba120 --> 012abc
24+
25+
// 2. Sort inline (multiline)
26+
cba
27+
210
28+
// Becomes
29+
abc
30+
012
31+
32+
// 3. Sort lines
33+
f
34+
e
35+
d
36+
// Becomes
37+
d
38+
e
39+
f
40+
41+
// 4. Sort lines based on length
42+
aaa
43+
aa
44+
a
45+
// Becomes
46+
a
47+
aa
48+
aaa
49+
50+
// 5. Sort lines (length reversed)
51+
b
52+
bbb
53+
bb
54+
bbbb
55+
// Becomes
56+
bbbb
57+
bbb
58+
bb
59+
b
60+
```
61+

Sort.novaextension/README.md

Lines changed: 47 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,51 @@ Extension for nova.app that allows you to perform simple sorting on highlighted
88

99
Currently you can sort in 4 different ways:
1010

11-
- Sort multiple lines based on a regular 0-9a-z sort.
12-
- Sort one or more lines internally. For example a line saying `cba` will say `abc`.
13-
- Sort multiple lines based by length (the number of characters including whitespace).
11+
- Sort multiple lines alphanumerically.
12+
- Sort content of one or more lines. For example a line containing `cba` will become `abc`.
13+
- Sort multiple lines based on length (the number of characters including whitespace).
1414
- Sort multiple lines based on length but reversed.
15+
16+
# Examples
17+
18+
```js
19+
// 1. Sort inline
20+
cba120 --> 012abc
21+
22+
// 2. Sort inline (multiline)
23+
cba
24+
210
25+
// Becomes
26+
abc
27+
012
28+
29+
// 3. Sort lines
30+
f
31+
e
32+
d
33+
// Becomes
34+
d
35+
e
36+
f
37+
38+
// 4. Sort lines based on length
39+
aaa
40+
aa
41+
a
42+
// Becomes
43+
a
44+
aa
45+
aaa
46+
47+
// 5. Sort lines (length reversed)
48+
b
49+
bbb
50+
bb
51+
bbbb
52+
// Becomes
53+
bbbb
54+
bbb
55+
bb
56+
b
57+
```
58+

Sort.novaextension/extension.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"name": "Sort",
44
"organization": "Chris DiLorenzo",
55
"description": "Sort lines by content or length in the editor.",
6-
"version": "1.3.4",
6+
"version": "1.3.5",
77
"categories": ["commands"],
88
"repository": "https://github.com/chrisdl/nova-sort",
99
"bugs": "https://github.com/chrisdl/nova-sort/issues",

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "nova-sort",
3-
"version": "1.3.4",
3+
"version": "1.3.5",
44
"description": "A Nova.app extension for sorting selections",
55
"main": "Sort.novaextension/Scripts/main.js",
66
"repository": {

0 commit comments

Comments
 (0)