Forward jumping to the next young file is implemented. The starting
position from which the next young file is searched is the next
position. If no young file has been found, the search starts from the
beginning. It stops at the initial position where the search has
started.
according to the manpage, it won't have any effect on 64bit system
anyways. and musl always uses 64bit so this macro doesn't have any
effect there either.
this avoids multiple printf calls and instead decodes the buffer
natively. using %NN instead of %-NNc also saves two bytes per run.
helpstr is also made `static` to avoid unnecessary stack allocation.
this makes it so that if the cp/mv commands are changed the in the
future, it will continue to work reliably instead of having hardcoded
indexes to modify the array.
the `#ifdef __linux__` is also removed, compilers should be smart enough
to see that PROGRESS_{CP,MV} are unused (on non-linux systems) and
optimize it out.
- Clear filter only when a plugin is selected manually.
Plugin dir should be unfiltered when opened.
- Plugins invoked by keys don't require clearing filter
of original context. If a new context is opened using
the plugin, it will be unfiltered by default. If the
same context is re-used (when all the contexts are in
use) the filter should be cleared so the the new path
is opened unfiltered.
the rename plugin always asks for "selection vs current" even when -u
flag is active. pass it to the plugin via `NNN_PREFER_SELECTION` so that
there's less distracting prompts.
in case the rotation is 0, `v >> (32 - r)` would end up doing a 32 right
shift which is equal to the width of `v` and thus undefined behavior.
ref: https://blog.regehr.org/archives/1063
* icons-hash: take total probe count into account as well
* icons-hash: use a better PRNG
the older method was using a multiplicative congruential generator (MCG)
which doesn't work too well especially with just 32 bits of state.
change it to a PCG instead with 64 bits of state (and 32 bits of output)
which should give better results.
and since we should get better rng - the search iteration has been
halved as well to save some build time.
* icons-hash: use an xor-rotate hash function
* icons-hash: fix some compiler warnings