Commit Graph

68 Commits

Author SHA1 Message Date
jsnal 8a87104009 fix(shellcheck): fix mangled backslashes with read
Fixes SC2162

https://github.com/koalaman/shellcheck/wiki/SC2162
2020-05-15 15:00:24 -04:00
jsnal 8683c4d974 refactor(pull request): update usage and sleep command per pull request
Add a list of supported binaries for the `-p` flag and use read instead
of sleep when falling back onto the bat.
2020-05-15 14:57:20 -04:00
jsnal 0c11309a4d fix(shellcheck): fix oneline if-then-else shellcheck
Fixes SC2015 and SC2086

https://github.com/koalaman/shellcheck/wiki/SC2015
https://github.com/koalaman/shellcheck/wiki/SC2086
2020-05-14 20:17:32 -04:00
jsnal 864d0149ce feat(usage): update usage for new previewer feature
Add the documentation for changing the FZF previewer binary. The help
page kind of looks weird now that the alignment is off. That is
something that might need to be refactored in the future.
2020-05-14 19:47:08 -04:00
jsnal 5f50b2e042 feat(flash): allow the use of previewers other than bat
This commit adds a way of changing the FZF previewer by using the `-p`
flag. An example of this might look like:

$ flash -p cat

This will use cat has the FZF previewer instead of bat. However, it keeps bat as
the default program in all cases unless specifically changed by the `-p`
parameter. There are also checks to see if the provided binary actually
exists on the system. If it exists on the system, it checks if it
supported by flash. If it isn't supported by flash, it falls back onto
bat as the default previewer. For now, only bat and cat are supported but it.
can easily be expanded.
2020-05-14 19:41:11 -04:00
jsnal 18c3e510f2 fix(setup): fix setup on macOS
Fix the setup function on macOS by removing the `eval` in the `touch`
statement. This fix worked for me on macOS 10.14.6, however, this hasn't
been tested with other versions of macOS. I checked that the script still works in
Linux as well.
2020-05-14 14:31:34 -04:00
Bryan Jenks d73faea243 less echo cmd calls, same output 2020-05-09 05:31:26 -07:00
Bryan Jenks 1ba3b21993 resolves #23 2020-05-07 20:12:58 -07:00
Bryan Jenks a1e17bad9d fix function close brace 2020-05-07 14:05:14 -07:00
Bryan Jenks 15e8648e4b when mac install coreutils, alias gshuf to shuf 2020-05-07 13:59:20 -07:00
Bryan Jenks e239411053 messed up mac home variable creation 2020-05-07 13:57:18 -07:00
Bryan Jenks 448648ca84 fix final shell checks 2020-05-05 20:55:57 -07:00
Bryan Jenks 3530948c4a new help/info system resolves #14 2020-05-05 20:54:02 -07:00
Bryan Jenks a37873cf0c version number aesthetics completed 2020-05-05 20:15:36 -07:00
Bryan Jenks a0b1582aaa building opts capturing for version and help msg 2020-05-05 20:11:40 -07:00
Bryan Jenks 5273ba6410 shell checks completed and functionality retained 2020-05-05 19:42:55 -07:00
Bryan Jenks 516cd4016c shell check cleanup and clear on answer screen exit 2020-05-05 19:33:33 -07:00
Bryan Jenks e30be22339 prefer XDG over hard coded paths, resolves #17 2020-05-04 13:07:23 -07:00
Bryan Jenks 2f6e8b6c11 Add opt to quit at question screen & clear output 2020-05-04 13:05:45 -07:00
Bryan Jenks 10ac67e47c another #15 fix for control of keys on scoring 2020-05-04 11:26:55 -07:00
Bryan Jenks 949d92fde7 add prompts for keypresses resolves #15 2020-05-04 11:22:54 -07:00
Bryan Jenks 24975ea398 comments and change whitespace to escape chars 2020-05-04 10:59:21 -07:00
Bryan Jenks 59dea80580 Merge branch 'master' of github.com:tallguyjenks/fla.sh 2020-05-03 15:49:27 -07:00
Bryan Jenks 3de1eb344f change diplay in terminal from flash.sh to fla.sh 2020-05-03 15:48:55 -07:00
Mark Coolen 032afa2f53 Fixed up grammar and syntax in the examples 2020-05-03 08:10:36 -04:00
Bryan Jenks cd5d74016f remove slash from find command, why did i even... 2020-05-02 15:18:17 -07:00
Bryan Jenks 739088a887 rmeove that backslash for mac, doesnt work 2020-05-02 15:17:14 -07:00
Bryan Jenks 23baa6d535 escape mac path space for tocu cmd 2020-05-01 19:12:27 -07:00
Bryan Jenks 5c717b1537 remove a command substitution 2020-05-01 14:20:59 -07:00
Bryan Jenks 0b1f60a960 change find commands from no path to './' 2020-05-01 13:56:01 -07:00
Bryan Jenks 9ab26d58fd try a command substitution 2020-04-29 15:26:40 -07:00
Bryan Jenks 1a243be7d0 replace brace expansion, try eval 2020-04-29 15:19:30 -07:00
Bryan Jenks 620e8474bd make setup code into function 2020-04-28 23:08:11 -07:00
Bryan Jenks c8391d9b25 seperate out touch commands for mac 2020-04-28 22:40:21 -07:00
Bryan Jenks 11b847b635 Revert "add path arg to find command"
This reverts commit 46deb034fd.
2020-04-28 22:37:06 -07:00
Bryan Jenks 9341bdac98 move around brace expansion for file gen 2020-04-28 15:23:01 -07:00
Bryan Jenks e3e6f5f50d please work 2020-04-27 15:05:46 -07:00
Bryan Jenks 46deb034fd add path arg to find command 2020-04-27 14:18:46 -07:00
Bryan Jenks d163f26445 fix cmd substitution for mac version? 2020-04-27 13:55:30 -07:00
Bryan Jenks 6b03a3b76e fix duplicative path section in info msg 2020-04-27 13:54:37 -07:00
Bryan Jenks 871f493f33 change hard coded file path in info msg 2020-04-27 13:52:30 -07:00
Bryan Jenks a842f6a7c7 remove hard coded number of recursive DIR searches 2020-04-27 13:49:17 -07:00
Bryan Jenks 397155be10 quote more filepaths for mac build 2020-04-27 13:26:36 -07:00
Bryan Jenks 7ce1aa4197 quote a variable that broke mac build 2020-04-27 12:55:21 -07:00
Bryan Jenks 4d98f47c25 mac friendly version 2020-04-26 19:25:02 -07:00
Bryan Jenks a62cd44939 make other variables flexible, rely on $DIR 2020-04-22 22:10:57 -07:00
Bryan Jenks 5d8b4b6637 resolves #8, average, and session logging 2020-04-21 22:07:57 -07:00
Bryan Jenks be5930a376 allow user to quit at score entry too 2020-04-21 20:54:32 -07:00
Bryan Jenks 4a9862bb02 resolves #7, highscore feature 2020-04-21 20:47:40 -07:00
Bryan Jenks b2a3168454 resolves #9 + tidying and commenting 2020-04-21 20:18:31 -07:00