Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Add option to Open with specified program #199

Open
wants to merge 46 commits into
base: master
Choose a base branch
from

Conversation

bogdan-the-great
Copy link

I missed this functionality from nnn so I added it. The second option O opens program detached from the terminal in background so I stated that this option is made for opening GUI programs and doing stuff in fff at the same time.

@bogdan-the-great
Copy link
Author

I added more things to my fork, but I'll leave it opened if someone needs it.

Such as:
- Don't show details if folder is empty.
- Warning message now skipable by pressing any key.
- Added `Permission denied` warning.
- Changed folders to not be bold.
Changes:
- Multiple file open with (normal and detached)
- Move status line one line down and hide it on messages/actions
- Hide cursor on `Permission denied` warning
- Fixed icons reappearing after entering a directory from history
- Let user mark multiple files with multiple directories at time
- Fixed marks not reappearing after entering a directory with marks
Changes:
- Added sixel support (which requires img2sixel command from libsixel)
- Removed colored filenames (mostly to speed things up a bit)
- Increased the number of currently visible lines by 1 to take advantage of previous changes with the status line
- Fixed creating a file
- Fixed icon disappearing after opening directory from history
- Changed rename command look
- Fixed weird history behaviour with current cursor position formatting
- Fixed disappearing icons when going back from history
- Tried to speed things up (and have in plans to overhaul the behaviour of opening the directory to make it even faster)
This commit optimizes (FINALLY!) the `ctrl` + `d/u` actions.

It does it by not printing 14 lines line-by-line, but it jumps quickly to the desired line, and if it isn't on screen, then it will quickly jump to the last visible edge, and then print line-by-line. This speeds up jumping a lot when details are on, but still relies on the speed of printing a line.

Printing a line could be made faster only by doing two things:
1. Heavily refactoring the whole `read_dir` and associated functions, to implement some sort of lazy loading for directories.
2. Make details more faster by using other tools for checking date and time. Less refactoring, but still some.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant