rabite0 / hunter Goto Github PK
View Code? Open in Web Editor NEWThe fastest file manager in the galaxy!
License: Do What The F*ck You Want To Public License
The fastest file manager in the galaxy!
License: Do What The F*ck You Want To Public License
While searching using S
it is useful to have incremental search to see partial match and correct search faster. Similar to incsearch
in vim.
hunter crashes on startup. Need to investigate.
See: #12
In the README when you refer to hunter, you refer to the project as hunter or the program hunter
? Should it be spelled hunter / Hunter?
Any chance you could add this to Homebrew?
It would be great if you could publish packages/let people contribute packages.
So you e.g. get a list like this: https://github.com/BurntSushi/ripgrep/tree/31adff6f3c4bfefc9e77df40871f2989443e6827#installation
See also: https://rust-lang-nursery.github.io/cli-wg/tutorial/packaging.html
Is it possible to change the keybindings? Or would I have to change the source for that?
Using the latest version of Rustup and a freshly installed Pop! OS I keep running into an error every single time I run
cargo install hunter
the error I get is
I already double checked and all my gstreamer things were installed correctly. Not sure why I am getting this error. Oh and your preinstalls for Ubuntu/Debian give me this error
Reading package lists... Done Building dependency tree Reading state information... Done E: Unable to locate package gstreamer1.0-devel E: Couldn't find any package by glob 'gstreamer1.0-devel' E: Couldn't find any package by regex 'gstreamer1.0-devel' E: Unable to locate package gst-plugins-base E: Unable to locate package gst-plugins-good
I can get the program to crash on my machine doing the following:
1/ go to my home folder (either from within hunter, or start hunter from ~)
2/ press 's'
I get the following stack trace.
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: AsyncError("Not ready yet!")', src/libcore/result.rs:997:5
stack backtrace:
0: std::sys::unix::backtrace::tracing::imp::unwind_backtrace
at src/libstd/sys/unix/backtrace/tracing/gcc_s.rs:39
1: std::sys_common::backtrace::_print
at src/libstd/sys_common/backtrace.rs:70
2: std::panicking::default_hook::{{closure}}
at src/libstd/sys_common/backtrace.rs:58
at src/libstd/panicking.rs:200
3: std::panicking::default_hook
at src/libstd/panicking.rs:215
4: std::panicking::rust_panic_with_hook
at src/libstd/panicking.rs:478
5: std::panicking::continue_panic_fmt
at src/libstd/panicking.rs:385
6: rust_begin_unwind
at src/libstd/panicking.rs:312
7: core::panicking::panic_fmt
at src/libcore/panicking.rs:85
8: core::result::unwrap_failed
9: alloc::slice::<impl [T]>::sort_by::{{closure}}
10: alloc::slice::merge_sort
11: hunter::files::Files::sort
12: <hunter::listview::ListView<hunter::files::Files> as hunter::listview::Listable>::on_key
13: <hunter::file_browser::FileBrowser as hunter::widget::Widget>::on_key
14: hunter::widget::Widget::handle_input
15: hunter::main
16: std::rt::lang_start::{{closure}}
17: std::panicking::try::do_call
at src/libstd/rt.rs:49
at src/libstd/panicking.rs:297
18: __rust_maybe_catch_panic
at src/libpanic_unwind/lib.rs:92
19: std::rt::lang_start_internal
at src/libstd/panicking.rs:276
at src/libstd/panic.rs:388
at src/libstd/rt.rs:48
20: main
21: __libc_start_main
22: _start
sorting by size in other folders works for me though
It will be cool to add Nerd Fonts support to display icons like LSDeluxe
Right now hunter just pipes stdout/stderr to a textview, but this means subprocesses don't know about the terminal size and don't use colors unless forced with flags. This could be improved by plumbing everything through the pseudo-terminal interface.
Additionally it would be nice if it was possible to send input to those subprocesses, turning hunter into a real TUI-shell (proxy).
Bulk renaming is the only thing stopping me from never using Ranger.
https://github.com/ranger/ranger/wiki/Official-user-guide#bulk-renaming
OS: Arch Linux
Terminal: Alacritty 0.2.9
Hunter Version: 1.0.1 (evil branch) (also happens in master branch)
Steps to Reproduce
hunter
q
Expected Results
After exiting the terminal is restored to its previous state.
Actual Results
After exiting it's no longer possible to scroll or click in the Alacritty window. Doing so outputs what appears to be raw escape sequences that look like this:
65;52;47M65;52;46M65;52;46M65;52;46M65;52;46M64;52;46M64;52;46M64;52;46M0;52;46M0;52;46m0;52;46m0;52;46m0;33;64M32;34;64M32;34;65M32;35;65M0;35;65m
Use the same approach than Kakoune.
Example – Print selected files:
eval "set -- $s"
# Using a for-loop
for file do
echo "$file"
done
# Using printf
printf '%s\n' "$@"
Compiling the version 1.0.1 in Manjaro I got 5 compiling errors like this:
error[E0658]: imports can only refer to extern crate names passed with `--extern` on stable channel (see issue #53130)
--> src/main.rs:62:5
|
41 | mod tabview;
| ------------ not an extern crate passed with `--extern`
...
62 | use tabview::TabView;
| ^^^^^^^
|
= help: add #![feature(uniform_paths)] to the crate attributes to enable
Command used: cargo build --release
Workaround: adding #![feature(uniform_paths)]
at the start of main.rs makes the project compile.
Currently hunter preview archives with 7z, but it does not support many widely used archive formats, like tgz, tar.gz, tar.xz. I suppose we can preview archives like ranger.
For example, ranger use atool
or bsdtar
(while atool
is not available) to preview tgz(https://github.com/ranger/ranger/blob/b1abf1327f38853f0101c585c2b1e868df400f9d/ranger/data/scope.sh#L52).
How about adding a batch_cmd
option to batch rename / delete – and more generally, for batch processing – a set of selections?
Example – Batch processing with Batch:
~/.config/hunter/config
batch_cmd=batch
Hey,
Thank for the project! You are doing well. :)
On compiling phase via AUR
on Arch Linux, I am getting this:
error[E0554]: #![feature] may not be used on the stable release channel
--> /home/dentrax/.cargo/registry/src/github.com-1ecc6299db9ec823/hunter-1.1.0/src/main.rs:1:1
|
1 | #![feature(vec_remove_item)]
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error[E0554]: #![feature] may not be used on the stable release channel
--> /home/dentrax/.cargo/registry/src/github.com-1ecc6299db9ec823/hunter-1.1.0/src/main.rs:2:1
|
2 | #![feature(trivial_bounds)]
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
error[E0554]: #![feature] may not be used on the stable release channel
--> /home/dentrax/.cargo/registry/src/github.com-1ecc6299db9ec823/hunter-1.1.0/src/main.rs:3:1
|
3 | #![feature(try_trait)]
| ^^^^^^^^^^^^^^^^^^^^^^
error[E0554]: #![feature] may not be used on the stable release channel
--> /home/dentrax/.cargo/registry/src/github.com-1ecc6299db9ec823/hunter-1.1.0/src/main.rs:4:1
|
4 | #![feature(fnbox)]
| ^^^^^^^^^^^^^^^^^^
error: aborting due to 4 previous errors
For more information about this error, try `rustc --explain E0554`.
error: failed to compile `hunter v1.1.0`, intermediate artifacts can be found at `/tmp/cargo-installTlPHje`
Similar to: #15
But, I am new to Rust; So, I don't exactly understand the Rust specific terms. How could we solve the this bug (with box-of-the-box way)?
cargo: cargo 1.34.0
rustc: rustc 1.34.0
Thanks!
--show-hidden
→ --all
-h
→ -a
-h
for helpWhen I move the mouse over the terminal window and touch scroll, or click mouse buttons, program start behaving strangely.
U
,D
,)
,’
\
are renderedAlso, annoying event shows up on the bottom, that says me to not use the mouse, but this I could ignore.
I'd suggest just disable terminal mouse events, so users could use mouse for simply selecting the text, to be copied elsewhere.
There are a few issues with the show_hidden
implementation from what I can tell.
h
which should be toggling the hidden files actually is overridden by the vim h
mapping. I am guessing l
has the same problem too.thread 'main' panicked at 'index out of bounds: the len is 0 but the index is 0', /rustc/bc44841ad2a2ad5f6c5e67b9e35ed8e7e71d4dc7/src/libcore/slice/mod.rs:2539:10
stack backtrace:
0: std::sys::unix::backtrace::tracing::imp::unwind_backtrace
1: std::sys_common::backtrace::_print
2: std::panicking::default_hook::{{closure}}
3: std::panicking::default_hook
4: hunter::die_gracefully::{{closure}}
5: std::panicking::rust_panic_with_hook
6: std::panicking::continue_panic_fmt
7: rust_begin_unwind
8: core::panicking::panic_fmt
9: core::panicking::panic_bounds_check
10: hunter::file_browser::FileBrowser::cache_files
11: <hunter::file_browser::FileBrowser as hunter::widget::Widget>::refresh
12: <hunter::file_browser::FileBrowser as hunter::widget::Widget>::on_key
13: hunter::widget::Widget::handle_input
14: hunter::main
15: std::rt::lang_start::{{closure}}
16: std::panicking::try::do_call
17: __rust_maybe_catch_panic
18: std::rt::lang_start_internal
19: main
The error triggers if I go back one more step. I started hunter in the folder ~/.config/hunter
Hunter output breaks if the terminal is too wide. It seems to happen when there are more than 197 columns in the terminal.
It only show a line on the first row and on the bottom row.
It happens both in gnome-terminal
and alacritty
.
# Terminal width
$ tput cols
197
On macOS, compilation currently fails with the following error message:
Compiling hunter v1.0.1 (/Users/mendler/Code/upstream/hunter)
error[E0432]: unresolved import `notify::INotifyWatcher`
--> src/fscache.rs:1:14
|
1 | use notify::{INotifyWatcher, Watcher, DebouncedEvent, RecursiveMode};
| ^^^^^^^^^^^^^^ no `INotifyWatcher` in the root
That's because inotifywatch
is Linux-specific.
I recommend https://github.com/passcod/notify for cross-platform filesystem notifications.
If you scroll fast (e.g. continually depress the down-arrow to move the cursor down a list), input becomes "laggy" and doesn't stop as soon as input stops.
Expected: cursor should stop immediately when the key is released
Actual: when you release the key the cursor continues for a few extra lines. The longer the key was held, the further "extra distance" the cursor goes, thus giving it an "inertial" effect.
Would be really cool if Hunter had devicons built in. Here is an example of what I mean, [https://github.com/alexanderjeurissen/ranger_devicons](Ranger Devicons) .
I am unable to compile it on my device with the latest from master branch.
Compiling hunter v1.0.1 (/Users/meain/Documents/Projects/projects/hunter)
error[E0432]: unresolved import `notify::INotifyWatcher`
--> src/fscache.rs:1:14
|
1 | use notify::{INotifyWatcher, Watcher, DebouncedEvent, RecursiveMode};
| ^^^^^^^^^^^^^^ no `INotifyWatcher` in the root
warning: unused import: `Watcher`
--> src/fscache.rs:1:30
|
1 | use notify::{INotifyWatcher, Watcher, DebouncedEvent, RecursiveMode};
| ^^^^^^^
|
= note: #[warn(unused_imports)] on by default
error: aborting due to previous error
For more information about this error, try `rustc --explain E0432`.
error: Could not compile `hunter`.
To learn more, run the command again with --verbose.
A lot of people had problems compiling hunter, because they weren't using a recent enough nightly compiler.
Solution:
A check in build.rs and bail with a warning when they're not on rust-nightly.
I'm trying to compile hunter in evil mode - release 1.0.2 and I'm getting this error:
error[E0554]: #![feature] may not be used on the stable release channel
--> src/main.rs:1:1
|
1 | #![feature(vec_remove_item)]
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error[E0554]: #![feature] may not be used on the stable release channel
--> src/main.rs:2:1
|
2 | #![feature(trivial_bounds)]
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
error[E0554]: #![feature] may not be used on the stable release channel
--> src/main.rs:3:1
|
3 | #![feature(try_trait)]
| ^^^^^^^^^^^^^^^^^^^^^^
error[E0554]: #![feature] may not be used on the stable release channel
--> src/main.rs:4:1
|
4 | #![feature(fnbox)]
| ^^^^^^^^^^^^^^^^^^
error: aborting due to 4 previous errors
For more information about this error, try `rustc --explain E0554`.
I understand why this error occurs and how I might be able to fix - by using the nightly version of rustc
but I was wondering whether you have any plans in not using non-stable features of rustc
such as this. I'm using Arch Linux and rust
version 1.33.0.
thread 'main' panicked at 'index out of bounds: the len is 1 but the index is 1', /rustc/d628c2e642c6f8f85f24dd5d7f49de89b95bf682/src/libcore/slice/mod.rs:2689:10
note: Run with `RUST_BACKTRACE=1` environment variable to display a backtrace.
Ubuntu 18.04 Stable with Zsh, oh my zsh & Tmux. Let me know if there's anything else I can do to help.
I was using the "filter" function.
Add ImageView and VideoView widgets.
Implement ImageView based on Sixel graphics and VideoView by integrating mpv playback.
Compilation on Xubuntu 18.04 failed due to a missing library:
= note: /usr/bin/ld: cannot find -lmagic
collect2: error: ld returned 1 exit status
Installing the libmagic-dev
package allowed compilation to succeed. I suggest putting all the non-Rust dependencies in the readme.
Reproduce:
While in hunter in any state, even just after starting the program:
l
for log viewq
to quitExpected: hunter should quit cleanly
Actual: hunter panics, ^C
required to exit
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: "SendError(..)"', src/libcore/result.rs:999:5
stack backtrace:
0: 0x10067a7f3 - std::sys::unix::backtrace::tracing::imp::unwind_backtrace::h42ef8f910989f2a5
1: 0x100676792 - std::sys_common::backtrace::_print::h57563d504eb2a535
2: 0x100679716 - std::panicking::default_hook::{{closure}}::hd122b1df844d64a4
3: 0x1006794bf - std::panicking::default_hook::h95cc52151fdfa338
4: 0x100533d60 - hunter::die_gracefully::{{closure}}::h4943948830babf57
5: 0x100679f70 - std::panicking::rust_panic_with_hook::h14fcc8bcee6073e2
6: 0x1006799bc - std::panicking::continue_panic_fmt::ha9475004e44b6b49
7: 0x1006798a8 - rust_begin_unwind
8: 0x1006917c1 - core::panicking::panic_fmt::h6b286a6a4688064c
9: 0x1004d1e92 - core::result::unwrap_failed::h4a6b49db654acb5f
10: 0x1004e6715 - std::sys_common::backtrace::__rust_begin_short_backtrace::h3b996df650fb3134
11: 0x1004e81e1 - std::panicking::try::do_call::haf5b9d3e62f44c81
12: 0x1006820ae - __rust_maybe_catch_panic
13: 0x1004ff1a1 - core::ops::function::FnOnce::call_once{{vtable.shim}}::h8de97fa96955d774
14: 0x10066c2cd - <alloc::boxed::Box<F> as core::ops::function::FnOnce<A>>::call_once::h981e060567c31168
15: 0x10068175d - std::sys::unix::thread::Thread::new::thread_start::h565ff451d36149b1
16: 0x7fff666c32ea - _pthread_body
17: 0x7fff666c6248 - _pthread_start
^C
Note that ^C
in the above output is not an interrupt of the output, the full backtrace is shown.
macOS 10.14.4 (18E226)
rustc 1.36.0-nightly (3991285f5 2019-04-25)
What is the equivalent to the following lf commands, which use fzf and fd?
Example – Select a file:
cmd select-fuzzy ${{
lf -remote "send $id select $(fd --type file | fzf)"
}}
map s select-fuzzy
Example – Change to a directory:
cmd cd-fuzzy ${{
lf -remote "send $id cd $(fd --type directory | fzf)"
}}
map g cd-fuzzy
It would be helpful to look up the help without leaving hunter
.
Instead of pressing the same key.
Specifically this code needs a good justification as to why it isn't unsound:
Line 67 in 15e2f89
This look to me like a "just make it compile" use of unsafe
; I hope you can explain how I'm wrong.
PREVIEWERS
hunter comes with definitions to enable previewing certain file typse. To use this you need to install some programs first. You can also define your own. See below. Defaults are:
bat / highlight for syntax highlighting 7z for archives w3m / links / elinks / lynx for html pdftotext / mutool for pdf
Debian/Ubuntu
**apt install gcc libmagic-dev gstreamer1.0-devel gst-plugins-base gst-plugins-good**
Fix typo: typse
==> types
The installation dependencies are not for Debian/Ubuntu.
This works for me (Ubuntu 18.04):
apt-get gcc libgstreamer-plugins-base1.0-dev gstreamer1.0-plugins-good
libmagic.so
is provided by libmagic1
package, but I have the feeling it is not required anymore by hunter as tree_magic
is now used instead of mime_detective
.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.