Simple tasks to get involved

From D Wiki
Revision as of 11:25, 21 December 2016 by Greenify (talk | contribs) (init page)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

If one looks at the high-level vision document there are many projects one can start to change the status quo.

However, as most of them might require a lot of time or expertise, here are a couple of ideas from the high-level vision that have been semi-automated and could be a good start for everyone to get involved:

Improve Code coverage

Since a couple of months, code coverage reports are enabled for all dlang repos and while this helps a lot for new contributions (especially with the browser extension [1]), there are still a lot of modules that can be incrementally improved.

How-to: have a look at the CodeCov page and pick your favorite module -> find uncovered lines -> add tests -> submit a PR:

https://codecov.io/gh/dlang/phobos

You can also see the output locally for a single module with:

make -f posix.mak std/math.test

and then browse the `std-math.lst` file.

[1] https://github.com/codecov/browser-extension

Make sure every function in Phobos has an example

Issue: https://issues.dlang.org/show_bug.cgi?id=16990

Script: https://github.com/wilzbach/style-checkers/blob/master/has_public_example.d

Example: https://github.com/dlang/phobos/pull/4973

How-to: Run the script to find functions without examples -> add examples for a module -> submit a PR

Make sure every function in Phobos has Params: and Returns:

Issue: https://issues.dlang.org/show_bug.cgi?id=16989

Script: https://github.com/Hackerpilot/Dscanner/pull/390

How-to: Run the Dscanner plugin to find functions without Params/Returns -> add them for a module -> submit a PR

Review @safe usage in Phobos (or @system -> @safe)

How-to: Pick your favorite module and search for '@system.*unittest' -> have a look whether the function can be done in SafeD -> submit PR

(alternatively one can also review the use of @trusted)

Example: https://github.com/dlang/phobos/pull/4690

Guide: http://dlang.org/safed.html

Enable more Dscanner plugins/automation for Phobos

Config: https://github.com/dlang/phobos/blob/master/.dscanner.ini

How-to: find your favorite, disabled Dscanner plugin -> enable it -> run dscanner on Phobos (`make -f posix.mak style`) -> fix the errors -> submit a PR

Start to watch & review PR reviews

How-to: Subscribe to DMD/Druntime/Phobos and watch the PRs reviews. After a while, you should be able to start pointing problem and adding feedback yourself.