-
Notifications
You must be signed in to change notification settings - Fork 427
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
Executable tutorial Submission: Integrating Code Climate in developers workflow with shell scripts and docker #1395
Conversation
… contributions/course-automation/badal-johennin/README.md
…ME.md to contributions/course-automation/badal-johennin/README.md" This reverts commit f88c5a5.
Proposal
add link to tutorial and improved readme
@Atema your time to shine! |
Great! I'll send you my feedback tomorrow morning |
Alright @johennin and @LeeBadal, here you go: FeedbackOverallYour tutorial explains two different concepts: shell scripts and Code Climate, which is nice, because the reader gets to learn a lot, but can also be a bit confusing: make sure to clearly separate which of the two does what! This may not be something that you can integrate into the tutorial (although it would be nice if you could elaborate a bit on alternative solutions), but it's not really clear to me what the advantages are of using a shell script over automation tools that are made for exactly this (for example, Gradle, Maven, or Grunt). You mention the importance of having an easy style guide with one command to run ( Bit short. The tutorial feels a bit on the short side (probably less than 10 minutes). You could expand a bit on the possibilities of Code Climate, e.g. by showing plugins like PyLint, or by adding something about the online dashboard/overviews they provide (more here). Background storyLooks good! The background story gives a nice context to the tutorial. IntroductionThe section gives a good introduction to what will happen in the tutorial. However, I'd like to see a bit more information about Code Climate, as I think most readers will not be familiar with the tool. It could also be made a bit clearer that we will do two different things: creating a shell script ánd Step 1Clear & straightforward (it could be marked as an optional step, as everything is currently run locally). Step 2Clear & straightforward. Could be combined with step 1 (clone repository, and open it) and step 3 (create test.sh). Step 3Introduction. It would be nice to have a short introduction to the file, so that you immediately know what's going on. Very much like you did in earlier in the tutorial for all files, just to remind the reader again. The code. I'm not sure whether you wrote this script yourself, or whether you got it from Code Climate (if the latter, maybe take these with a grain of salt), but I've got a few technical things. Engine install. According to their instructions under Project setup on https://github.com/codeclimate/codeclimate, Using subshell. By writing the commands inside parentheses, they are run in a subshell, so you don't need to Codeclimate install check. Currently, you check whether the directory Rewrite. Implementing these changes, you could rewrite to something like: #!/usr/bin/env bash
if [ ! -f "/usr/local/bin/codeclimate" ]
then
curl -L https://github.com/codeclimate/codeclimate/archive/master.tar.gz | tar xvz -C /home/$USER/
(cd /home/$USER/codeclimate-* && sudo make install)
fi
codeclimate engines:install
python3 tests/test.py
codeclimate analyze Line numbers. It would be nice to be able to copy the code snippet without having to navigate to GitHub. You could embed a gist with the snippet (see https://blog.medium.com/yes-we-get-the-gist-1c2a27cdfc22), which would also provide syntax highlighting, making things a bit easier to read. (I don't think there's a dark mode, so it may not fit in well with the rest). Line-by-line explainations. Nice to show precisely what happens, especially for people not really familiar with shell scripts. You could expand a bit further, and explain each line instead of combining lines. Step 4Introduction. Same as for the previous step, a short introduction to the file to remind the reader would be nice. Explainations. Code Climate is one of the main focuses of your tutorial, so I would expect more information about how its config files work. Currently, the config is quite long and even contains a section that's commented out. You could instead write your own config file, that demonstrates what Code Climate is capable of, and explain the options you include. Step 5Straightforward & clear. Step 6Straightforward & clear. You should update the the string that's printed (either here or at the other places), as it's not consistent with the version in the GitHub repo and the screenshot in step 8. Step 7Straightforward. You could expand a bit by adding some more different types of issues, and linking them back to your config file in step 4. Step 8Again, "hello tests" is not consistent with step 6. Otherwise, this step is clear. Maybe you could mention to make sure that the Docker daemon is running? It gave me some problems the first time I ran the script. Step 9Nice! ConclusionLooks good! It would be nice if you expanded a bit more on the "many ways of automating processes like these" and their pros and cons. Easter eggWas very difficult to find, and took me a while to get what your hint meant. |
Let me know if you have any questions :) |
Make sure to create a PR for feedback submission! |
@Atema Thanks for the feedback, we changed it a bit. Specifically explaining the config options more detailed, matching the output with the image and rewriting the script. @khaes-kth We are ready for a review/merge. |
@LeeBadal Please make list the changes you made after the feedback in your README file. |
Also, I think you should not change the |
|
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.
Removed the problem README.me file from the commit, @khaes-kth
Original PR proposal can be found here: #1278.
The tutorial on Medium can be found here.
Easter Egg
It might be hard to find at first so here is a hint:
Check all the characters in the links!