If you are willing to try this to see why I keep getting what I think are
trivial conflicts, here are two recent branches that implement small
improvements and cause this conflict.  My sympy git repo is
git://github.com/ryanGT/sympy.git

There is a branch called mainvar that allows the user to pass a main
variable to latex print Add so that the terms are sorted according to the
exponents of that variable.  You can also specifiy that you want the
exponents in descending order:
git pull github mainvar

Then I created a branch called inline that allows inline=None to mean don't
wrap the latex output in any environment and don't put it in $...$ either:
git pull github inline

(Obviously, you don't have github as pointing to my repo....)


Basically, I am adding several small features that are related but sort of
independent.  I want others to have the option of tweaking or elminating
them individually.  I thought multiple branches was the way to go.

Thanks for your help,

Ryan

On Wed, Jun 24, 2009 at 12:23 PM, Vinzent Steinberg <
vinzent.steinb...@googlemail.com> wrote:

> 2009/6/24 Ryan Krauss <ryanli...@gmail.com>
>
>> So, I have a personal git sympy repo on github and have finally learned
>> enough to be useful to the project (I hope).
>>
>> Question #1:
>>
>> One problem I ran into is that while I was figuring things out and
>> cleaning up the mess I made of my own branches, other people submitted
>> various patches.  So, I think I correctly rebased my  branches, but I get a
>> lot of messages about conflicts that seem to be related to stuff that got
>> added to the end of a file.  When I go into edit the conflicting files, they
>> look like this:
>>
>> def test_mainvar():
>>     expr = 3*x*y**3+x**2*y+x**3+y**4
>>     profile_y = {'mainvar' : y}
>>     assert latex(expr, profile_y) == '$x^{3} + y x^{2} + 3 x y^{3} +
>> y^{4}$'
>>     profile_x = {'mainvar' : x}
>>     assert latex(expr, profile_x) == '$y^{4} + 3 x y^{3} + y x^{2} +
>> x^{3}$'
>>     profile_y['descending'] = True
>>     assert latex(expr, profile_y) == '$y^{4} + 3 x y^{3} + y x^{2} +
>> x^{3}$'
>>     profile_x['descending'] = True
>>     assert latex(expr, profile_x) == '$x^{3} + y x^{2} + 3 x y^{3} +
>> y^{4}$'
>> <<<<<<< HEAD:sympy/printing/tests/test_latex.py
>> =======
>>
>> def test_inline():
>>     expr = x+y
>>     assert latex(expr) == '$x + y$'
>>     assert latex(expr, inline=None) == 'x + y'
>>     assert latex(expr, inline=False)== '\\begin{equation*}x +
>> y\\end{equation*}'
>> >>>>>>>
>> a66e0937464156e8abc6d48e8484f6ec855d36c5:sympy/printing/tests/test_latex.py
>>
>> Why can't git figure out that I just want my new function at the end of
>> the file?  What is the conflict here?  How do I create patches or clean up
>> my branches so that everyone who checks out my branch doesn't have to delete
>> those extra lines from the supposed conflict?
>>
>
> I'm not sure about this one, I'd have to try out. Maybe you have to use
> "git merge" explicitly?
>
>
>>
>>
>> Question #2:
>>
>> If I create a branch or patch to fix an issue that I identified, what do I
>> need to do to submit the solution?  Do I need to first create an issue on
>> http://code.google.com/p/sympy/issues ?  Is it enough to email the patch
>> to this list?  Can I instead email a branch I would like to suggest?  Do I
>> not need to email, but instead just create an issue?
>
>
> All these variants are perfectly valid and have different
> advantages/disadvantages:
>
> 1. e-mail a patch: easy to comment, comfortable once "git email" works, can
> be forgotten (one day hopefully not anymore)
> 2. file an issue with patch: harder to comment, won't be forgotten
> 3. e-mail a link to a branch: easy to get (especially for many commits) and
> test, less issues than with patches, efficient, can be commented on github
>
> For small changes patches are nice, for larger changes pull requests are
> the way to go.
> Most sympy developer use any variant according to their mood. :)
>
> Hopefully this answers your questions.
>
>
>>   Or something else?
>>
>> Basically, what is the git workflow for contributing to sympy with github?
>
>
> You get a repository on github you can push to and other people can pull
> from it and review a branch.
> I'm not sure, but maybe Ondrej covered this in his brand-new video
> tutorials.
>
>
> Vinzent
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"sympy-patches" group.
To post to this group, send email to sympy-patches@googlegroups.com
To unsubscribe from this group, send email to 
sympy-patches+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/sympy-patches?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to