How can a line be sorted relative to other lines at the same indentation level?
This would be useful whenever adding an item to an ordered list of definitions (file lists or forward definitions).
Currently you need to:
- Move to the start of the block
- Start selecting.
- Move to the end of the block.
- Sort the items.
Being able to order a newly added item in a block would be a more efficient way to handle this.
Examples could include:
/* Structs, keep in order. */ struct FooBar; struct FooBaz; struct FooFoo; struct AbcBaz; /* <- cursor on this line. */
CMake file list:
set(SRC zaz.c # <- cursor on this line. bar.c baz.c foo.c )
Running this action would sort the current line in respect to surrounding lines.