You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucy.apache.org by rectang <gi...@git.apache.org> on 2012/09/22 00:17:59 UTC
[lucy-dev] lucy pull request: Separate Clownfish and CFC
GitHub user rectang opened a pull request:
https://github.com/apache/lucy/pull/1
Separate Clownfish and CFC
* `Clownfish::CFC` is a compiler written in C. It has no prerequisites
aside from the host language.
* `Clownfish` is the Clownfish core (Hash, CharBuf, VTable, Method, etc.).
It depends on `Clownfish::CFC`.
The plan here is to copy the Clownfish core, work on it until it builds on its
own, then integrate it into the Lucy core and once that's complete, delete the
originals from the Lucy core.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/rectang/lucy cfish_core
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/lucy/pull/1.patch
----
commit d67219935d9ddd4e7a6506f82067d88b84aaf2b9
Author: Marvin Humphrey <ma...@rectangular.com>
Date: 2012-09-19T14:17:00-07:00
Move CFC one level down into clownfish/cfc.
commit cc0ad416395890859ca5097248f220741dfa7ed3
Author: Marvin Humphrey <ma...@rectangular.com>
Date: 2012-09-19T14:31:53-07:00
Copy Clownfish files into place.
Copy source files for Clownfish core classes out of Lucy directories.
No build yet, as the files are copied verbatim.
commit c9852a6bb710d7aa1763be00b0b97690b5259c20
Author: Marvin Humphrey <ma...@rectangular.com>
Date: 2012-09-19T15:15:52-07:00
Get charmonize and CFC to build.
commit c55d66dd674d29fe18f6aa327c25838d0300df77
Author: Marvin Humphrey <ma...@rectangular.com>
Date: 2012-09-19T16:23:02-07:00
Remove superfluous build subroutines.
commit 0bf05e5706a93c85c5394fab7a8d35334418c2a8
Author: Marvin Humphrey <ma...@rectangular.com>
Date: 2012-09-19T16:23:42-07:00
Adapt Clownfish::Build::Binding for new layout.
commit 851f0b1050147f97118d142f5c5844fa097b7401
Author: Marvin Humphrey <ma...@rectangular.com>
Date: 2012-09-19T16:47:29-07:00
Remove serialization capabilities.
commit 55a37493585dbf66b57cdf485f4c4607318661ed
Author: Marvin Humphrey <ma...@rectangular.com>
Date: 2012-09-20T17:13:12-07:00
Remove references to Lucy/Util/ToolSet.h.
commit d8114a907784065a8e88027864e9589bfc976c40
Author: Marvin Humphrey <ma...@rectangular.com>
Date: 2012-09-20T17:14:00-07:00
Purge Lucy from Clownfish.pm.
commit f9932dc0c300f98e4ca4ca80719b096979a9275f
Author: Marvin Humphrey <ma...@rectangular.com>
Date: 2012-09-21T12:06:00-07:00
Change parcel from Lucy to Clownfish.
----
Re: [lucy-dev] lucy pull request: Separate Clownfish and CFC
Posted by Chris Hostetter <ho...@fucit.org>.
: Otherwise, you'll have to fetch the remote branch and rebase it against
: master. This is more complicated:
FWIW: there is something to be said for treating the pull request exactly
the same as you would a patch atttached to Jira -- namely: commit the
patch.
For the short time Lucy is still on SVN, this might not maintain as much
information as working with a git2svn bridged checkout if pull request
contains multiple commits -- but (unless i'm way off base) once you are
using git then running "git am" on a patch URL fro ma pull request will
preserve everything, and should be less hassle then working with remote
branches.
(says the guy who understands the theory of git, but has never actaully
run "git am")
-Hoss
Re: [lucy-dev] lucy pull request: Separate Clownfish and CFC
Posted by Nick Wellnhofer <we...@aevum.de>.
On 24/09/2012 21:00, Marvin Humphrey wrote:
> Also, it's inconvenient but we cannot close pull requests submitted against
> the Github mirror. This has to do with Github not offering permissions for
> organizations which are fine-grained enough to meet the needs of Apache. (If
> I understand correctly, the problem is that if individual PMC members get
> permission to close pull requests, they also get permission to do other stuff
> which Infra is not OK with.)
I remember that the permission system of Github "organizations" was very
coarse-grained initially. But it seems to have improved:
https://help.github.com/articles/what-are-the-different-access-permissions
But I guess the requirements of the ASF are more complex or simply
different.
> I believe that if we commit a pull request without modifications, there's some
> sort of mechanism which detects that we have done so (presumably by examining
> commit SHAs) and closes the pull request automatically. But if we rebase or
> otherwise modify the commits, that won't happen.
Yes, Git objects are always identified by their SHA hash. If git detects
a fast-forward merge, it will (by default) simply replay the commits
without creating a merge commit.
>> This is easy if we're OK with non-linear
>> commit history or the pull request is based on the latest commit:
>>
>> git checkout master
>> git pull $repo_url $remote_branch
>> [ handle merge conflicts ]
>> git push origin master
>
> This is the debate I'd argued we should put off for a bit. The command
> sequence is certainly simpler in this case, but transitioning to a non-linear
> commit history has non-trivial implications.
+1
>> Otherwise, you'll have to fetch the remote branch and rebase it against
>> master. This is more complicated:
>>
>> # Fetch from remote repository
>> git fetch $repo_url $remote_branch:temp_branch
>> git checkout temp_branch
>>
>> # Rebase
>> git rebase master
>> [ handle rebase conflicts ]
>>
>> # Merge and push
>> git checkout master
>> git merge temp_branch
>> git push origin master
>>
>> # Cleanup
>> git branch -d temp_branch
>
> Nice recipe. :) If we were on Git already, I would follow it.
There are of course more advanced ways to work with remote branches.
I'll try to document the general Git workflow on a Wiki page (creating
tracking branches, pushing to / pulling from remote branches). I always
found Git cheatsheets incredibly useful.
> In general what I explect to do going forward is...
>
> 1. Make a handful of commits to a feature branch in the Lucy ASF repo.
> 2. Gather consensus on the dev list if appropriate (because the change
> affects the public API or is a substantial enough change to the
> implementation). This might be done before or after before or after the
> initial commits to the feature branch.
> 3. If and when the feature passes muster, merge it to master.
> 4. Delete the feature branch.
+1
Nick
Re: [lucy-dev] lucy pull request: Separate Clownfish and CFC
Posted by Marvin Humphrey <ma...@rectangular.com>.
On Mon, Sep 24, 2012 at 6:12 AM, Nick Wellnhofer <we...@aevum.de> wrote:
> The merge has to be done manually.
+1
We can't accept a pull request directly into
<https://github.com/apache/lucy.git> -- we need to update the canonical repo
on Apache hardware and let the mirroring routines propagate the change out to
Github.
Also, it's inconvenient but we cannot close pull requests submitted against
the Github mirror. This has to do with Github not offering permissions for
organizations which are fine-grained enough to meet the needs of Apache. (If
I understand correctly, the problem is that if individual PMC members get
permission to close pull requests, they also get permission to do other stuff
which Infra is not OK with.)
I believe that if we commit a pull request without modifications, there's some
sort of mechanism which detects that we have done so (presumably by examining
commit SHAs) and closes the pull request automatically. But if we rebase or
otherwise modify the commits, that won't happen.
> This is easy if we're OK with non-linear
> commit history or the pull request is based on the latest commit:
>
> git checkout master
> git pull $repo_url $remote_branch
> [ handle merge conflicts ]
> git push origin master
This is the debate I'd argued we should put off for a bit. The command
sequence is certainly simpler in this case, but transitioning to a non-linear
commit history has non-trivial implications. (Always `merge --no-ff`?
Discipline for supporting `bisect`? Must all conflicts be handled in the
merge commit? And so on...)
> Otherwise, you'll have to fetch the remote branch and rebase it against
> master. This is more complicated:
>
> # Fetch from remote repository
> git fetch $repo_url $remote_branch:temp_branch
> git checkout temp_branch
>
> # Rebase
> git rebase master
> [ handle rebase conflicts ]
>
> # Merge and push
> git checkout master
> git merge temp_branch
> git push origin master
>
> # Cleanup
> git branch -d temp_branch
Nice recipe. :) If we were on Git already, I would follow it.
As it stands, I'm just going to replay the commits manually on Subversion
(after modifying the directory layout to use Moritz's suggestion), which will
continue our existing linear commit history.
In general what I explect to do going forward is...
1. Make a handful of commits to a feature branch in the Lucy ASF repo.
2. Gather consensus on the dev list if appropriate (because the change
affects the public API or is a substantial enough change to the
implementation). This might be done before or after before or after the
initial commits to the feature branch.
3. If and when the feature passes muster, merge it to master.
4. Delete the feature branch.
In this case, I used my Github fork to host the feature branch. I could also
have used a branch in our current svn repo, but I wanted to audition the
Github pull request apparatus and have this conversation.
Marvin Humphrey
Re: [lucy-dev] lucy pull request: Separate Clownfish and CFC
Posted by Nick Wellnhofer <we...@aevum.de>.
On 24/09/2012 06:19, Logan Bell wrote:
> I'm a little bit confused about the workflow in regard to pull requests. Is
> it possible for us to accept pull requests into the apache project or do we
> have to manually merge them into a local git repo and push back to apache?
The merge has to be done manually. This is easy if we're OK with
non-linear commit history or the pull request is based on the latest commit:
git checkout master
git pull $repo_url $remote_branch
[ handle merge conflicts ]
git push origin master
Otherwise, you'll have to fetch the remote branch and rebase it against
master. This is more complicated:
# Fetch from remote repository
git fetch $repo_url $remote_branch:temp_branch
git checkout temp_branch
# Rebase
git rebase master
[ handle rebase conflicts ]
# Merge and push
git checkout master
git merge temp_branch
git push origin master
# Cleanup
git branch -d temp_branch
Nick
Re: [lucy-dev] lucy pull request: Separate Clownfish and CFC
Posted by Logan Bell <lo...@gmail.com>.
I'm a little bit confused about the workflow in regard to pull requests. Is
it possible for us to accept pull requests into the apache project or do we
have to manually merge them into a local git repo and push back to apache?
Thanks,
Logan
On Fri, Sep 21, 2012 at 3:17 PM, rectang <gi...@git.apache.org> wrote:
> GitHub user rectang opened a pull request:
>
> https://github.com/apache/lucy/pull/1
>
> Separate Clownfish and CFC
>
> * `Clownfish::CFC` is a compiler written in C. It has no
> prerequisites
> aside from the host language.
> * `Clownfish` is the Clownfish core (Hash, CharBuf, VTable, Method,
> etc.).
> It depends on `Clownfish::CFC`.
>
> The plan here is to copy the Clownfish core, work on it until it
> builds on its
> own, then integrate it into the Lucy core and once that's complete,
> delete the
> originals from the Lucy core.
>
> You can merge this pull request into a Git repository by running:
>
> $ git pull https://github.com/rectang/lucy cfish_core
>
> Alternatively you can review and apply these changes as the patch at:
>
> https://github.com/apache/lucy/pull/1.patch
>
> ----
> commit d67219935d9ddd4e7a6506f82067d88b84aaf2b9
> Author: Marvin Humphrey <ma...@rectangular.com>
> Date: 2012-09-19T14:17:00-07:00
>
> Move CFC one level down into clownfish/cfc.
>
> commit cc0ad416395890859ca5097248f220741dfa7ed3
> Author: Marvin Humphrey <ma...@rectangular.com>
> Date: 2012-09-19T14:31:53-07:00
>
> Copy Clownfish files into place.
>
> Copy source files for Clownfish core classes out of Lucy directories.
> No build yet, as the files are copied verbatim.
>
> commit c9852a6bb710d7aa1763be00b0b97690b5259c20
> Author: Marvin Humphrey <ma...@rectangular.com>
> Date: 2012-09-19T15:15:52-07:00
>
> Get charmonize and CFC to build.
>
> commit c55d66dd674d29fe18f6aa327c25838d0300df77
> Author: Marvin Humphrey <ma...@rectangular.com>
> Date: 2012-09-19T16:23:02-07:00
>
> Remove superfluous build subroutines.
>
> commit 0bf05e5706a93c85c5394fab7a8d35334418c2a8
> Author: Marvin Humphrey <ma...@rectangular.com>
> Date: 2012-09-19T16:23:42-07:00
>
> Adapt Clownfish::Build::Binding for new layout.
>
> commit 851f0b1050147f97118d142f5c5844fa097b7401
> Author: Marvin Humphrey <ma...@rectangular.com>
> Date: 2012-09-19T16:47:29-07:00
>
> Remove serialization capabilities.
>
> commit 55a37493585dbf66b57cdf485f4c4607318661ed
> Author: Marvin Humphrey <ma...@rectangular.com>
> Date: 2012-09-20T17:13:12-07:00
>
> Remove references to Lucy/Util/ToolSet.h.
>
> commit d8114a907784065a8e88027864e9589bfc976c40
> Author: Marvin Humphrey <ma...@rectangular.com>
> Date: 2012-09-20T17:14:00-07:00
>
> Purge Lucy from Clownfish.pm.
>
> commit f9932dc0c300f98e4ca4ca80719b096979a9275f
> Author: Marvin Humphrey <ma...@rectangular.com>
> Date: 2012-09-21T12:06:00-07:00
>
> Change parcel from Lucy to Clownfish.
>
> ----
>
>