Commit Graph

140 Commits

Author SHA1 Message Date
Přemysl Eric Janouch 98c8dc5b7d
Fix tilde expansion algorithm
In principle correct, in practice completely broken.

I wrongly assumed basic_string::find() would behave like strcspn(),
and also used a nonsensical string index to check for the tilde.
2020-09-28 02:00:29 +02:00
Přemysl Eric Janouch b99f96cf6a
Fix comment: the word "no-op" needs to be split 2020-09-28 01:46:38 +02:00
Přemysl Eric Janouch 5759df156b
Support tilde expansion in the "chdir" action
The tilde may be escaped, and this first escape may be escaped
as well, so all paths should be expressable.

All will just work(TM) for those who need it, and those who start
filenames with backslashes are begging to have their foot shot.

It appears that even Shift JIS, Big5, GB 18030, and GBK are
compatible with Unix paths, meaning they don't redefine the slash
(0x2F), so I'm okay with my direct multibyte string handling in
unknown locales.

Legacy stuff smells.
2020-09-28 01:45:56 +02:00
Přemysl Eric Janouch 91df92f49a
Make F3 change directories
Best complemented with a less(1) configuration that also quits on F3,
just like mcview.  Or invoke sdn with PAGER=mcview, even though you
lose the ability to view the help that way (but gain filters).
2020-09-27 23:33:10 +02:00
Přemysl Eric Janouch bff886841b
Always accept ^? as well as ^H as backspace 2020-09-21 21:15:15 +02:00
Přemysl Eric Janouch ebb444dda1
README: add an example of configuring bindings 2020-09-15 19:36:19 +02:00
Přemysl Eric Janouch da0252ff98
README: make it also work with asciidoctor 2020-09-15 19:31:54 +02:00
Přemysl Eric Janouch 98da5f6d35
Add an action to go to the parent directory 2020-09-15 19:15:30 +02:00
Přemysl Eric Janouch f4eebf59af
README: make listings hswg-compatible 2020-08-28 18:33:08 +02:00
Přemysl Eric Janouch 63982b3754
README: make listings libasciidoc-compatible 2020-08-28 18:30:49 +02:00
Přemysl Eric Janouch d6eaf44aee
README: fix upstream URL 2020-08-28 18:25:32 +02:00
Přemysl Eric Janouch b8344f215c
Name change 2020-08-28 18:23:46 +02:00
Přemysl Eric Janouch 623c4914d1
Work around an infinite loop issue 2020-04-19 22:40:57 +02:00
Přemysl Eric Janouch c0f0328762
README: fix integration snippets
Runs of whitespace used to be smashed together.
2020-02-13 20:33:16 +01:00
Přemysl Eric Janouch 571ec74706
Guard against ^Z in helper programs
Resume them immediately, we are not a shell.
2019-12-09 19:01:16 +01:00
Přemysl Eric Janouch 7cce0cc2fd
Fix change notifications
Another embarrassing 71fbaca regression.
2019-09-27 23:06:12 +02:00
Přemysl Eric Janouch bf38e4e9ea
Position indicator like in vi 2019-09-27 22:38:48 +02:00
Přemysl Eric Janouch 2c847fb4a3
Add actions imitating L/M/H in vi 2019-09-27 21:08:12 +02:00
Přemysl Eric Janouch 296c0cc66f
Fixes for previous commits
".." used to be hidden together with hidden files,
and the symlink patch introduced a compiler warning.
2018-12-09 05:29:59 +01:00
Přemysl Eric Janouch 71fbaca9e5
Embrace paths with symbolic links 2018-12-08 01:41:41 +01:00
Přemysl Eric Janouch 4ce6454ebb
Add Norton Commander-like actions for F3 and F4 2018-12-03 22:05:00 +01:00
Přemysl Eric Janouch 315b662581
Don't show .. in the root directory 2018-12-03 22:04:35 +01:00
Přemysl Eric Janouch 4a2a49312b
Fix formatting 2018-12-03 00:11:00 +01:00
Přemysl Eric Janouch 7174b507d3
Fix crash on unknown groups 2018-12-01 15:57:35 +01:00
Přemysl Eric Janouch aae9c392fa
Also sort symlinks to directories first 2018-11-10 01:32:59 +01:00
Přemysl Eric Janouch fad0d264a5
Support old libstdc++ 4.9
Now sdn can be built under Debian jessie with clang++ and libstdc++.
2018-11-04 19:46:06 +01:00
Přemysl Eric Janouch 473aa8788c
Update README 2018-11-03 17:04:50 +01:00
Přemysl Eric Janouch 85ada4dd2b
Fix build on not-my-system 2018-11-03 15:23:31 +01:00
Přemysl Eric Janouch e6ed7da395
Update README 2018-11-03 15:01:39 +01:00
Přemysl Eric Janouch c065238e75
Reliability improvement 2018-11-03 15:01:19 +01:00
Přemysl Eric Janouch 579e4c9a34
Make confirming a search choose the item 2018-11-02 22:12:34 +01:00
Přemysl Eric Janouch 3c056dde91
Add screenshot to README 2018-11-02 21:19:41 +01:00
Přemysl Eric Janouch 081b4db5c3
Fix level popping 2018-11-02 20:22:50 +01:00
Přemysl Eric Janouch 36454fb90c
Fix history loading 2018-11-02 18:30:36 +01:00
Přemysl Eric Janouch 6b1ff048b8
Flash column when sorting is changed 2018-11-02 18:30:35 +01:00
Přemysl Eric Janouch 3790f8dfa0
Allow changing the sort column
Directories always come first and the .. entry even before that.
2018-11-02 18:07:06 +01:00
Přemysl Eric Janouch 5c086016b5
Allow hiding so-called hidden files 2018-11-02 17:45:18 +01:00
Přemysl Eric Janouch 232ecffa2d
Allow reversing the sort 2018-11-02 17:25:10 +01:00
Přemysl Eric Janouch f3fffe4b25
Add an action to quit without chdir
Also fixed ACTION_CHOOSE_FULL to quote properly.
2018-11-02 15:50:58 +01:00
Přemysl Eric Janouch 77313663a3
Update README 2018-11-02 15:40:56 +01:00
Přemysl Eric Janouch 5f2eaa88e0
Create the config directory if needed 2018-11-02 15:37:56 +01:00
Přemysl Eric Janouch d6846e6327
Add an action for chdir 2018-11-02 15:09:27 +01:00
Přemysl Eric Janouch 314ba114a1
Implement messages to the user 2018-11-02 15:05:04 +01:00
Přemysl Eric Janouch 4de89faf7e
Store runtime and configuration to a file
Added a toggle for gravity, now turned off by default.
2018-11-02 14:48:16 +01:00
Přemysl Eric Janouch beee2e2683
Unnecessary c_str() 2018-11-02 12:35:03 +01:00
Přemysl Eric Janouch 4ab0db3c04
Make sure to quote empty strings 2018-11-02 12:08:43 +01:00
Přemysl Eric Janouch 3624636c2f
New config parser
Basically a subset of Bourne shell.
2018-11-01 22:42:49 +01:00
Přemysl Eric Janouch e80c56e249
Cleanup 2018-11-01 22:19:31 +01:00
Přemysl Eric Janouch 2c595100ae
Fix setcchar invocation 2018-11-01 20:05:06 +01:00
Přemysl Eric Janouch e4af5b4147
Remember cursor position in ancestor directories 2018-11-01 19:40:05 +01:00