-
Notifications
You must be signed in to change notification settings - Fork 27
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
UX improvements #35
UX improvements #35
Conversation
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.
Just one comment and one tip/idea. Otherwise LGTM.
README.md
Outdated
|
||
Options: | ||
-c, --config TEXT Configuration name. | ||
--debug Enable debugging mode (debugging logs, full tracebacks). |
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.
What about adding also -d
for debug?
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.
The problem I have with that is whether we want to reserve -d for such operation. It's not gonna be used that much, mostly just by us. Not every option needs to have a shorter variant, only the ones used most of the time
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.
Yes, you're right. It will be usefull only for us.
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.
Here, the help output should be updated as well.
README.md
Outdated
### Directly from git | ||
|
||
``` | ||
$ python3 -m colin.cli.colin -h |
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.
Good to know this syntax.
But it will not install/load the config files. (Would be nice to have #34 for this.)
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.
yup, I agree; let's finish #34 first
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.
@phracek please advise on how one can invoke colin directly from git
README.md
Outdated
### Directly from git | ||
|
||
``` | ||
$ python3 -m colin.cli.colin -h |
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.
Add before running help these two lines:
$ git clone https://github.com/user-cont/colin && cd colin
$ pip-3 install . --user
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.
Give me a mmnt. Testing it inside container.
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.
If you don't need it now, I will take a WFT (work-from-train..;-) and implement the loading from the file tonight.
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.
Clarified with this Dockerfile:
FROM fedora:27
RUN dnf install -y python3-pip git libattr-devel gcc redhat-rpm-config \
python3-devel \
&& dnf clean all
RUN git clone https://github.com/user-cont/colin /files/colin \
&& cd /files/colin \
&& pip-3 install . --user \
&& python3 -m colin.cli.colin -h
Usage: colin.py [OPTIONS] TARGET
Options:
-c, --config TEXT Configuration name.
--json FILENAME File to save the output as json to.
-s, --stat Print statistics instead of full results.
-h, --help Show this message and exit.
---> 5c3bfb005664
Removing intermediate container d72fc5f12e36
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.
Good suggestion, I updated the readme a bit more.
b1cf2e2
to
394a0fc
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.
Only need to update the usage and we can merge.
(Could you also rebase to have better git-tree?)
README.md
Outdated
We can now run the analysis: | ||
|
||
``` | ||
$ python3 -m colin.cli.colin -c TBD fedora:27 |
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.
Now, you can use -f ./config/fedora.json
.
How do I rebase? |
394a0fc
to
75b63b7
Compare
fixed, ready for re-review |
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.
Examples are great, but help messages are not updated.
README.md
Outdated
Usage: colin.py [OPTIONS] TARGET | ||
|
||
Options: | ||
-c, --config TEXT Configuration name. |
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.
colin -h
Usage: colin [OPTIONS] TARGET
Options:
-c, --config [rhel|fedora] Select a predefined configuration.
--debug Enable debugging mode (debugging logs, full tracebacks).
-f, --config-file FILENAME Path to a file to use for validation (by
default they are placed in /usr/share/colin).
--json FILENAME File to save the output as json to.
-s, --stat Print statistics instead of full results.
-h, --help Show this message and exit.
README.md
Outdated
|
||
Let's give it a shot: | ||
``` | ||
$ colin -f ./config/rhel.json rhel7 |
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.
s/./config/rhel.json
/./config/redhat.json
You are changing the code too fast, I can't keep up! |
Related user-cont#32 Signed-off-by: Tomas Tomecek <ttomecek@redhat.com>
Related user-cont#33 Signed-off-by: Tomas Tomecek <ttomecek@redhat.com>
75b63b7
to
c2251f7
Compare
updated |
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.
LGTM
Nice work! Thanks
TODO: