diff options
author | rabite <rabite@posteo.de> | 2019-05-21 20:50:54 +0200 |
---|---|---|
committer | rabite <rabite@posteo.de> | 2019-05-21 20:52:04 +0200 |
commit | e8d9c6ad1f82d6b0bbf3cf9449ce53dd525cb77a (patch) | |
tree | e9615c4cf832f1a17a640a229c5dd79710ad601e /README.md | |
parent | 6f8a6366039282cfce272a4a430590de83f48045 (diff) |
merge in media-preview stuff
Squashed commit of the following:
commit 4087cee2f2a72bc2d3e44832809cbe99d25a3309
Author: rabite <rabite@posteo.de>
Date: Tue May 21 20:40:27 2019 +0200
rename to preview-gen
commit 275fd420a01c24393ae9cc07287204fde309130a
Author: rabite <rabite@posteo.de>
Date: Tue May 21 20:30:50 2019 +0200
update Cargo.toml and README
commit bf4c3fec0f8e0ff4628153297ac64fe165b4e443
Author: rabite <rabite@posteo.de>
Date: Tue May 21 20:30:33 2019 +0200
add config options for media
commit 3bf681cd078177d634507c51d04a45bdae184f1b
Author: rabite <rabite@posteo.de>
Date: Tue May 21 13:46:00 2019 +0200
always use unicode icons for play/pause/mute
commit ed2a0b31d1911e4d42086699ca1db636c327bacf
Author: rabite <rabite@posteo.de>
Date: Tue May 21 13:04:11 2019 +0200
rename to mediaview and some fixups
commit bda3f8f83bec07c3f52d06cf5f8eaad7fdbd85a0
Author: rabite <rabite@posteo.de>
Date: Tue May 21 11:44:52 2019 +0200
fix warnings
commit 9c917903cfa958b225f268ed4fb9f55f27162be0
Author: rabite <rabite@posteo.de>
Date: Tue May 21 01:10:58 2019 +0200
play audio through viedo widget
commit 9fe208b213710fae889f7701bdb3bf96d599c9a8
Author: rabite <rabite@posteo.de>
Date: Tue May 21 00:15:12 2019 +0200
fixed play when autoplay is off
commit d4036d52864d0a4e08f7da2cf6f7419ef070c1a9
Author: rabite <rabite@posteo.de>
Date: Mon May 20 13:15:44 2019 +0200
add icons for play/pause/mute
commit 29f0d203cfd7501b50d80501de146da9d89388bb
Author: rabite <rabite@posteo.de>
Date: Mon May 20 12:26:53 2019 +0200
add basic gif support
commit 8d28e4c23a91b0ef83739554c3a2f6671a9ff6f5
Author: rabite <rabite@posteo.de>
Date: Mon May 20 11:43:57 2019 +0200
fixed play after pause
commit 142017df78de77bcfffd8f3dd9612a06927e183b
Author: rabite <rabite@posteo.de>
Date: Sun May 19 14:22:16 2019 +0200
change to stale on drop
commit c0026c7f56f6a841df18e41bd1c9b33543e26cfb
Author: rabite <rabite@posteo.de>
Date: Sat May 18 23:46:27 2019 +0200
handle errors in gstreamer closure
commit ef37f872c54b9d21ed5505c2edb480c793afaef9
Author: rabite <rabite@posteo.de>
Date: Sat May 18 23:40:24 2019 +0200
add image-only mode to preview-gen
commit 15752464563463c6ecf892c1d8a14651bf32e1e5
Author: rabite <rabite@posteo.de>
Date: Sat May 18 23:28:33 2019 +0200
add copyright note
commit 4c9f08fc4de5d3bffefd42284b60aa81cfbae9f7
Author: rabite <rabite@posteo.de>
Date: Sat May 18 23:27:30 2019 +0200
make image/video previews optional
commit 9c2c2db2b20ecd4c30acbb1c77ad18c71f528c4c
Author: rabite <rabite@posteo.de>
Date: Sat May 18 22:13:25 2019 +0200
remove blank space under video
commit f7056d70fbe9147b3b95d7c10950653eadbb4f48
Author: rabite <rabite@posteo.de>
Date: Sat May 18 22:06:49 2019 +0200
remove dbg
commit cce820657ff1258cdb78d455dd3cf04564450cea
Author: rabite <rabite@posteo.de>
Date: Sat May 18 21:50:25 2019 +0200
added error handling to preview-gen
commit 80bbe15bacb99d1f4f97504a5d10ecf59544993f
Author: rabite <rabite@posteo.de>
Date: Sat May 18 21:04:31 2019 +0200
add time and visual seek bars to videoview
commit 4349945cc5549334f246be64bc7c8e2db43f9150
Author: rabite <rabite@posteo.de>
Date: Thu May 16 22:39:19 2019 +0200
fix sneaky process
commit 373128b7096d4de29924617e549a613a3aeea5b2
Author: rabite <rabite@posteo.de>
Date: Thu May 16 22:07:27 2019 +0200
fix out of controll processes
commit e061e065e913ab3923ffac1079a9f0a2be0df532
Author: rabite <rabite@posteo.de>
Date: Thu May 16 20:51:56 2019 +0200
add media_preview
commit f68c754895a9718d1a962980de9fbf02e5cb48cd
Author: rabite <rabite@posteo.de>
Date: Thu May 16 19:37:04 2019 +0200
beta image/video previews
commit 9a5460e553dd26ebccffaf819c64a8dc6ba74818
Author: rabite <rabite@posteo.de>
Date: Tue May 14 20:36:25 2019 +0200
external img preview
commit 3c4edfcb7611b36f6e537c73743e0b6bd269037b
Author: rabite <rabite@posteo.de>
Date: Tue May 14 20:35:12 2019 +0200
video preview
Diffstat (limited to 'README.md')
-rw-r--r-- | README.md | 36 |
1 files changed, 20 insertions, 16 deletions
@@ -29,6 +29,7 @@ A big thanks to ranger and its developers. Without its inspiration this wouldn't * Exit and cd into last directory and put selected files into shell variables * Slide up animation for previews for a smoother experience (configurable) * Can show icons with the [right fonts](https://github.com/ryanoasis/nerd-fonts) +* Optional support for previews of image/video/audio files using Unicode half-block drawing @@ -45,16 +46,21 @@ If it works on a system not mentioned here, please open an issue. Also feel free * gcc * libmagic-dev * Rust-nighly compiler +* GStreamer for video/audio previews ### Debian/Ubuntu -* ```apt install gcc libmagic-dev``` +* ```apt install gcc libmagic-dev gstreamer1.0-devel gst-plugins-base gst-plugins-good``` ## INSTALLATION: Compiling hunter currently requires a nightly Rust compiler! The easiest way to get a nightly compiler is with [rustup](https://rustup.rs/). If you have rustup installed it will automatically download and use a version that is known to work when you run cargo. +By default it will install a full-featured version with support for media-previews. You can control this using the feature flags ```img```, and ```video```. These can be disabled by calling cargo with ```--features ""```, if you want to disable all media previews, or ```--features=img"``` if you only want to disable video/audio previews. + +Note that this only works if hunter can find the "preview-gen" tool somewhere in $PATH! + ### Install rustup ``` @@ -65,34 +71,26 @@ curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh ### Build with cargo ``` -cargo install hunter +cargo install (--features=...) hunter ``` ### Build from source ``` -// Clone the git repo -git clone https://github.com/rabite0/hunter.git +// Clone the git repo +git clone https://github.com/rabite0/hunter.git // Go into the repos directory cd {source_dir}/hunter/ -// Note: if you want vim bindings you will have to switch to the evil branch. -// git checkout evil +// (Optional) Build +// cargo build --release (--features=...) -// Build -cargo build --release +// Install +cargo install (--features=...) --path . ``` -### - -This will create a binary in {source_dir}/hunter/target/release/hunter. If you want to call this like any other terminal app you have to put this binary in your path. - -```ln -s {source_dir}/hunter/target/release/hunter /usr/bin/local/hunter``` - -This will link the the binary to your local bin file. You can call hunter from anywhere. To update repeat the process, but you will **not** need to redo the binary link. - ## NOTE: hunter uses [ranger's rifle](https://github.com/ranger/ranger/blob/master/ranger/ext/rifle.py) to open files if rifle is in your $PATH. If it can't find rifle it uses xdg-open. It also uses ranger's scope.sh to generate previews for non-text files. A slightly modified version is included in the "extra" directory. Put it in your $PATH somewhere if you want previews for non-text files. @@ -105,6 +103,8 @@ show_hidden=off select_cmd=find -type f | fzf -m cd_cmd=find -type d | fzf icons=off +media_autostart=off +media_mute=off ``` ## Drop into hunter cwd on quit @@ -160,6 +160,10 @@ By default hunter uses vi-style keybindings. If you use a QWERTY-like keyboard l | z | open subshell in cwd | | c | toggle columns | | F(n) | switch to tab | +| Alt(m) | toggle media pause and autoplay | +| Alt(M) | toggle media mute | +| Alt(>) | seek media +5s | +| Alt(<) | seek media -5s | |