[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
Re: [egit-dev] Having git config values in code templates
|
Hi Kyle,
Please check egit ui, there was already "variables" package AFAIK.
CU
Andrey
Am 3. Februar 2015 23:36:19 MEZ, schrieb "Kyle J. Harms" <kyle.harms@xxxxxxxxx>:
>Hi all,
>
>I'm the developer for this plugin. I'm trying to get this merged into
>egit. But I've got a couple of questions...
>
>I've got 3 class that do the work:
>GitVariableCommentResolver
>GitVariableJavaResolver
>GitVariableResolverHelper
>
>and one, RegisterResolvers, that just registers the
>GitVariableCommentResolver class. the GitVariableJavaResolver is taken
>care of in the plugin.xml. I know very little about the eclipse
>framework. This doesn't seem like fits with the current setup within
>egit. What would be the preferred approach for getting these
>registered within egit?
>
>I've looked over the egit project structure and I'm not familiar
>enough to know the best place to put my code. What project do these
>classes belong? org.eclipse.egit.core? org.eclipse.egit.ui? Is there a
>package that makes sense for me to place this code?
>
>I'll try and get this wrapped up as quickly as possible once I can
>figure out where to place these things and the preferred approach for
>registering them.
>
>Thanks,
>Kyle Harms
>
>On Tue, Jan 27, 2015 at 4:42 AM, Peter Palaga <ppalaga@xxxxxxxxxx>
>wrote:
>> I have created the enhancement issue to tract this effort:
>> https://bugs.eclipse.org/bugs/show_bug.cgi?id=458505
>> I have chosen "UI" as the component, plz. change it if it is not
>> appropriate. -- Peter
>>
>>
>> On 01/26/2015 02:16 PM, Matthias Sohn wrote:
>>>
>>> The contributor guide [1] describes how to contribute changes.
>>>
>>> In a nutshell the author needs to electronically sign the Eclipse
>>> Contribution License Agreement
>>> sign-off the commits he wants to contribute and push them for review
>using
>>>
>>> $ git push https://git.eclipse.org/r/egit/egit HEAD:refs/for/master
>>>
>>> or
>>>
>>> $ git push ssh://git.eclipse.org:29418/egit/egit
>>> <http://git.eclipse.org:29418/egit/egit> HEAD:refs/for/master
>>>
>>> [1]
>https://wiki.eclipse.org/EGit/Contributor_Guide#Contributing_Patches
>>>
>>> -Matthias
>>>
>>> On Mon, Jan 26, 2015 at 2:09 PM, Peter Palaga <ppalaga@xxxxxxxxxx
>>> <mailto:ppalaga@xxxxxxxxxx>> wrote:
>>>
>>> Thanks for the positive feedback, Max and Andrey. I'll try to
>ask
>>> the author first if he is not ready to go through the steps
>himself.
>>> -- PP
>>>
>>>
>>> On 01/26/2015 01:47 PM, Andrey Loskutov wrote:
>>>
>>> Not sure if this is really needed, as the code is really
>small &
>>> trivial.
>>>
>>> First of all I would suggest to create enhancement request
>in
>>> bugzilla for egit core describing what is the feature you
>want
>>> to add to egit, and refer to the plugin as one of the
>possible
>>> implementations. Second - convince the author to "rebase"
>his
>>> code (essentially 3 classes + one entry in plugin.xml) on
>top of
>>> egit (we have already
>org.eclipse.egit.ui.internal.__variables
>>> package, so it naturally belongs there) and submit a patch
>to
>>> egit project (the author used EPL, so it should be OK). CQ
>will
>>> be needed at the very end, if the patch will be accepted and
>>> exceeds 1000 lines, which is far more than the actual code
>has :-)
>>>
>>> On Monday 26 January 2015 13:26 Max Rydahl Andersen wrote:
>>>
>>>
>>> The code here is very simple and only depends on base
>>> eclipse bundles. I
>>> think it makes sense to have these variables made
>available
>>> via eclipse
>>> git ui bundle IMO.
>>>
>>> A PR would probably be the first step - and since its
>more
>>> than a few
>>> lines of code a CQ is probably needed to be opened by
>egit
>>> leads too,
>>> but since it is very simple and under EPL that would
>>> hopefully be easy
>>> to get done.
>>>
>>> /max
>>>
>>> Hi,
>>>
>>> I hope this has not been asked before.
>>>
>>> = Short version
>>>
>>> What needs to be done to make [1] a part of eGit?
>>>
>>> = Long version
>>>
>>> The @author tag of JavaDoc supposed to contain some
>kind
>>> of commonly
>>> understandable identifier of the author(s) of the
>given
>>> Java file.
>>>
>>> Developers often use their full name of a
>combination of
>>> the full name
>>> and e-mail address.
>>>
>>> As a matter of fact, there is no full name variable
>>> available in Java
>>> Code templates that are used when creating new Java
>>> files. There is
>>> only ${user} that resolves to the current user's
>login
>>> on the local
>>> machine which often fails to serve as a generally
>>> understandable
>>> identifier of the author.
>>>
>>> There is a couple of ways to workaround this (e.g.
>>> hand-edit the
>>> template, override java.user in eclipse.ini) but
>they
>>> are error prone
>>> and hard to enforce in team environments.
>>>
>>> I recently stumbled accross
>>> eclipse-git-template-variables plugin [1]
>>> that simply makes the values from git config
>available
>>> in java code
>>> templates. This solves the above problem very
>elegantly.
>>> However, making a team dependent on a plugin
>developend
>>> by an
>>> individual sounds quite risky.
>>> Therefore the question: What needs to be done to
>make
>>> [1] a part of
>>> eGit?
>>>
>>> I am not the author of the plugin, I do not know its
>>> internals and I
>>> even have not tried of it works. But if there is a
>>> chance that it
>>> could be included in eGit, I am ready to help in
>some
>>> form.
>>>
>>> [1]
>>>
>https://github.com/harmsk/__eclipse-git-template-variables
>>>
><https://github.com/harmsk/eclipse-git-template-variables>
>>>
>>> Thanks,
>>>
>>> Peter
>>> --
>>>
>>> Peter Palaga, Senior Sustaining Engineer, Red Hat
>JBoss
>>> Portal
>>>
>>>
>>>
>>> _________________________________________________
>>> egit-dev mailing list
>>> egit-dev@xxxxxxxxxxx <mailto:egit-dev@xxxxxxxxxxx>
>>> To change your delivery options, retrieve your password, or
>>> unsubscribe from this list, visit
>>> https://dev.eclipse.org/__mailman/listinfo/egit-dev
>>> <https://dev.eclipse.org/mailman/listinfo/egit-dev>
>>>
>>>
>>
>_______________________________________________
>egit-dev mailing list
>egit-dev@xxxxxxxxxxx
>To change your delivery options, retrieve your password, or unsubscribe
>from this list, visit
>https://dev.eclipse.org/mailman/listinfo/egit-dev
--
Kind regards,
Andrey Loskutov
http://google.com/+AndreyLoskutov