-
Notifications
You must be signed in to change notification settings - Fork 2.3k
plugin/less-pretty-cat improvements #1957
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
plugin/less-pretty-cat improvements #1957
Conversation
97ca99a
to
e6331c9
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Greetings all !
I have a few comments, many related to the core logic and not necessarily this PR
However : WHY ARE THERE 7 EMPTY FILES IN THIS PR?
If this is chained and waiting on another PR, let's mark it as a DRAFT until its ready.
fc8c2b9
to
5d9c97a
Compare
Rebased on master |
5d9c97a
to
538cefc
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking good I think we're almost there !
Addresses Bash-it#1632 Alsö, code style cleanup: quote variables, handle unbound parameters, &c.
Convert from indented if-block to return then unindented code. This should have basically one line change at the top, one line removed at the bottom, and then all whitespace.
538cefc
to
55fdcea
Compare
55fdcea
to
15d7edd
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lets move this one along ...
one last note: On cless
, although the docs mention a single file, the code actually cats ALL files and then pipes the result to less. I'm not going to hold up the PR on that but just wanted to call it out ...
The logic to run `cat` if `pygmentize` fails seems useless, so just remove it.
15d7edd
to
2ddb407
Compare
tweaked and pushed 👍 |
Description
Adopt
_command_exists
, quote variables, handle unbound parameters, code flow simplification.Motivation and Context
This was part of my
_command_exists
branch (#1938) but was out of scope.How Has This Been Tested?
Types of changes
Checklist:
clean_files.txt
and formatted it usinglint_clean_files.sh
.