-
-
Notifications
You must be signed in to change notification settings - Fork 89
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
Bash linting #116
Comments
That looks good and definitely something that will help, I tested it with a sample script and the suggestions were good. One downside might be with Bats support, as per: koalaman/shellcheck#417, which is not yet merged. |
That's a great point - I didn't see this before. If we were set on using shellcheck as a linter, we could omit testing the bats files. Equally, it seems as though there is a good PR attached to the issue, so hopefully it may be merged in the future (or just use the unmerged branch - people seem to think it works pretty well). Conversely, I have no particular attachment to shellcheck, and as such am happy to take suggestions for any other linters 🙂 |
Linting on the The solutions are submitted by contributors, and it would be nice to conform to conventions, but this has somewhat less exposure to a learner. |
I can give this a try and see how it goes after #104 is completed, since it's dependent on that. |
Any progress on this one @budmc29 ? 🙂 I imagine there will be a lot of edits with this. |
Forgot about this, I'll see what I can do in the following days. |
Did #148 take care of this? |
No, this is a different issue. |
I'll consider this. I'm going to focus on updating the out of date tests with the generator first, so we can get version files for everything. |
I'll check later today, but I believe shellcheck gets mad if you use I think if we implement it we will have to change all of our tests to use |
I see no issue with that, it's actually an improvement if my understand of how |
Okay, great. I will look into adding linting with shellcheck. I guess we will need to make other scripts and bin/* follow the same guidelines. |
I will look into this again after I have gotten a couple more exercises ported to the track. |
A glance through our example solutions suggests that most of them would need changing before they would pass linting with shellcheck. Some of them will need outright replacement |
I'll have another try at this. |
I have closed my attempt since I don't have that much time anymore, but if anyone is interested you can see the progress I made on #234 |
I'll close this. If anyone has time to pick it up, feel free to reopen. |
I've noticed that there isn't linting as part of the track yet. In my experience contributing to the Python track I see they have implemented linting, and it allows a greater track consistency.
I'd be interested in hearing other's thoughts around linting of code (and if anyone here has any particular favourites when it comes to linters for Bash).
A cursory glance points me towards shellcheck, which seems to integrate with Travis alright!
The text was updated successfully, but these errors were encountered: