| Commit message (Collapse) | Author | Age |
| |
|
| |
|
|
|
|
|
|
| |
Previously we were failing to clear the very last line when exiting.
Thanks to Zaplanincan for reporting the issue.
|
| |
|
|
|
|
|
|
|
|
| |
No real advantage, but I get to feel warm and fuzzy about
HEAP SUMMARY:
in use at exit: 0 bytes in 0 blocks
total heap usage: 8 allocs, 8 frees, 15,425 bytes allocated
|
| |
|
|
|
|
|
| |
To clarify that we aren't freeing the choices structure, just the
buffers associated with it.
|
|
|
|
|
|
| |
This would allow reading from multiple files (which we don't need) as
well as allowing us to free the buffer with the rest of the choices
structure (which is nice).
|
| |
|
| |
|
|
|
|
|
|
|
| |
Apparently GNU make doesn't like adding dependencies on that style of
pattern rule specification.
This reverts part of 887a0b4294001c95187eeaeff20ad748125466d7
|
|
|
|
|
|
| |
make now runs cleanly on default BSD make. This uglies it up a little,
but it was so close it might as well be made as widely compatible as
possible.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
Any values should work here, and it doesn't seem to make a siginificant
difference to startup time, as this only adds or reduces a few realloc
calls.
Starts input buffer at 4k of memory, which is nice for being the size of
a page and the size usually used in the read syscall. Initial choice
capacity set to 128, by assuming that candidates average 32 characters
long.
|
|
|
|
| |
Also refactored and added comments.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This should be slightly faster at loading the input into memory, since
fewer mallocs will be required vs running one malloc per-line of input.
Realloc on modern systems is fast. It can use mremap internally to remap
virtual memory pages and avoid copying. This can be seen in strace. Neat!
I thought that this might be friendlier to caching, but there was no
noticeable differnce when scanning through the strings for matches. It's
probable that the previous strdups placed them more-or-less contiguously
and the extra padding for malloc bookkeeping didn't make a significant
differnce. This also suggests that alignment of the candidate strings
wasn't important.
|
| |
|
| |
|
|
|
|
| |
This reverts commit de53af7e70bdc352513cabd40dcb4872052b701b.
|
| |
|
|
|
|
|
|
| |
Prefers "magic letters" to magic numbers. It's easier to think of all
control codes as their shifted versions of letters A-Z in the ascii
table.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
I get a few reports of enter not working with fzy occasionally. This
usually occurrs after running a badly behaved program which doesn't
clean up the tty properly (looking at you, pry) after cleaning the
ICRNL flag.
This commit now always unsets ICRNL. This also could have been fixed by
ensuring ICRNL was set, but I believe this will give more control over
keybindings.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
| |
This is helpful because some searches are an order of magnitude easier
than others.
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
Apologies that this uses my preferred formatting style: mostly the same
as Linux, but without a break between function and brace. Adds spaces in
a few places they weren't before.
|
|
|
|
|
| |
Adding sudo: false enables the container-based infrastructure, which
starts up almost instantly.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
| |
Allows us to interpret ^C through ^Z as control codes and handle them
properly.
Also fixes resetting termios after ^C
|
|
|
|
|
|
| |
Still needs to be fixed on an exit due to ^C
Thanks @rtandy
|
|
|
|
| |
See garybernhardt/selecta#56
|
| |
|
| |
|
|
|
|
| |
Makes it easy to run tests w/ gdb for debugging
|
| |
|