From: Lars Kurth <lars.kurth.xen@gmail.com>
To: Ishani <chugh.ishani@research.iiit.ac.in>
Cc: xen-devel <xen-devel@lists.xenproject.org>,
Doug Goldstein <cardoe@cardoe.com>,
Andrew Cooper <andrew.cooper3@citrix.com>
Subject: Re: [Outreachy] Interested in contribution: Code Standards Checking using clang-format
Date: Mon, 3 Apr 2017 12:00:11 +0100 [thread overview]
Message-ID: <9C7EF571-1659-4C42-8B20-155A7A542D19@gmail.com> (raw)
In-Reply-To: <1840515690.2929358.1490953052718.JavaMail.zimbra@research.iiit.ac.in>
Hi Ishani, (+Doug, +Andy)
not that the deadline as been extended to April 13. I am also CC'ing Andy Cooper as Doug has not responded.
The challenge that we will have is to satisfy the small task requirement while also making the task sensible in the context of the project. Now we do have some flexibility there: in other words, we can declare for example an RFC that everyone agrees with as such a contribution.
But as a basic idea, the first step of the project would be to try and come up with a .clang-format file that matches one of the coding styles in the git tree (either http://xenbits.xen.org/gitweb/?p=xen.git;a=blob;f=CODING_STYLE or http://xenbits.xen.org/gitweb/?p=xen.git;a=blob;f=tools/libxl/CODING_STYLE) and prove that it works. I don't know whether this is doable as a small task: the number of options in clang-format do not seem to be huge. And there are tools such as https://clangformat.com/ to experiment with.
If it is possible to do the whole thing in a small task, the output would be a .clang-format file that is submitted for code review to a suitable location in the xen tree. I don't know what the right location should be, but xen.git:tools/clang-format would be sensible.
If it is not possible to do this for one of the complete coding standards, I would develop for one or two subsets:
1: a .clang-format settings snippet for a reasonably complex coding style pattern in the coding standard
2: a piece of test code that adheres to the coding standard
3: a variant of the same code snippet that does not adhere to the coding standard
4: a small script that checks that .clang-format works correctly on these pieces of code
For 4, you probably want to run clang-format with -output-replacements-xml on the files in 1 - 3 and then do some grep magic to see whether it does the right thing.
Again this could go into xen.git:tools/clang-format - maybe under tools/clang-format/tests for now
@Andy, @Doug: does this sound sensible?
Regards
Lars
> On 31 Mar 2017, at 10:37, Ishani <chugh.ishani@research.iiit.ac.in> wrote:
>
> Hello Sir,
>
> I am Ishani Chugh, a fourth year undergraduate student of Electronics and Communications Engineering at International Institute of Information Technology, Hyderabad. I am passionate about Open Source Development. I am interested to contribute to your organization Xen Project as an Outreachy intern . I am interested to work in the project: Code Standards Checking using clang-format. I am proficient in C++ and have slight experience of working in clang-format.
> Please guide me for initial contributions to prove my candidature.
>
> Regards
> Ishani
>
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@lists.xen.org
> https://lists.xen.org/xen-devel
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
next prev parent reply other threads:[~2017-04-03 10:59 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-31 9:37 [Outreachy] Interested in contribution: Code Standards Checking using clang-format Ishani
2017-04-03 11:00 ` Lars Kurth [this message]
2017-04-03 12:01 ` Ishani
2017-04-03 16:22 ` Lars Kurth
2017-04-11 11:21 ` Ishani
2017-04-11 11:52 ` Lars Kurth
2017-04-16 20:00 ` Ishani
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=9C7EF571-1659-4C42-8B20-155A7A542D19@gmail.com \
--to=lars.kurth.xen@gmail.com \
--cc=andrew.cooper3@citrix.com \
--cc=cardoe@cardoe.com \
--cc=chugh.ishani@research.iiit.ac.in \
--cc=xen-devel@lists.xenproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.