- About Scala
- Documentation
- Code Examples
- Software
- Scala Developers
Re: Re: Scala Github repository is now live
Thu, 2011-12-01, 07:01
On Wed, Nov 30, 2011 at 9:59 PM, Daniel Spiewak wrote:
> Well we can't have that. :-) Just thought it was a valid question, since we all have to re-clone.
Nobody said it wasn't a valid question. We didn't do it lightly, but
fortunately we were able to do it on the same day.
Thu, 2011-12-01, 17:27
#2
Re: Re: Scala Github repository is now live
On Thu, Dec 1, 2011 at 8:11 AM, Eugene Burmako wrote:
> Hey folks! How do you feel about removing ".project" and putting it
> under project.SAMPLE in the same fashion as it's done for
> ".classpath".
Yes please.
Thu, 2011-12-01, 20:07
#3
Re: Re: Scala Github repository is now live
Another fall back for the lazy is "git diff master > patch.foo && git checkout new-master && git checkout -b new-branch && git apply patch.foo"
Except, you'll probably have conflicts there as well, depending on the patch. Note: the http://github.com/jsuereth/scala-repo-cleaner project has a filter-branch script you can run on your commits before rebasing that should line up whitespace and remove needless files from your repo before merging. I used it to help make migration easier (and to clean up the repository to begin with).
- Josh
On Thu, Dec 1, 2011 at 1:57 PM, Daniel Spiewak <djspiewak@gmail.com> wrote:
Except, you'll probably have conflicts there as well, depending on the patch. Note: the http://github.com/jsuereth/scala-repo-cleaner project has a filter-branch script you can run on your commits before rebasing that should line up whitespace and remove needless files from your repo before merging. I used it to help make migration easier (and to clean up the repository to begin with).
- Josh
On Thu, Dec 1, 2011 at 1:57 PM, Daniel Spiewak <djspiewak@gmail.com> wrote:
Try the following:
$ git checkout c4a613c58
$ git rebase -i 2d3fe5733cbc6bcf06892c8ee3cb19f7987f6b6a
<make sure to remove all commits except for c4a613c58>
Daniel
On Thu, Dec 1, 2011 at 12:53 PM, Daniel Sobral <dcsobral@gmail.com> wrote:I'll be more verbose. I have this (simple pull request being used as
guinea pig):
commit c4a613c585faca06ba4a077bfbf3e979c4e6657b
Author: Daniel C. Sobral <dcsobral@gmail.com>
Date: Mon Oct 31 14:12:59 2011 -0200
Example in scala.sys.process didn't match the text that describes it. Fixed.
commit 89b322757a36caaf10b1a38a6ca99c318c22e24c
Author: extempore <extempore@5e8d7ff9-d8ef-0310-90f0-a4852d11357a>
Date: Sat Oct 29 19:35:15 2011 +0000
Fix for crasher in explicitouter.
Closes SI-4970, review by moors.
git-svn-id:
http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@25912
5e8d7ff9-d8ef-0310-90f0-a4852d11357a
On the new-master (based on the new scala/scala), I found this:
commit 2d3fe5733cbc6bcf06892c8ee3cb19f7987f6b6a
Author: Paul Phillips <paulp@improving.org>
Date: Sat Oct 29 19:35:15 2011 +0000
Fix for crasher in explicitouter.
Closes SI-4970, review by moors.
So I checked out my pull request branch, and run this:
cs@ayanami:~/github/scala (process/fix)$ git rebase --onto
2d3fe5733cbc6bcf06892c8ee3cb19f7987f6b6a new-master
First, rewinding head to replay your work on top of it...
Applying: Syntax changes for tuples and sequences; symbols.
Using index info to reconstruct a base tree...
<stdin>:171: trailing whitespace.
case FLOATLIT: case DOUBLELIT: case STRINGLIT:
<stdin>:172: trailing whitespace.
case SYMBOLLIT: case NULL: case IDENTIFIER:
<stdin>:173: trailing whitespace.
case THIS: case SUPER: case IF:
<stdin>:174: trailing whitespace.
case FOR: case NEW: case USCORE:
<stdin>:210: trailing whitespace.
return make.Select(pos,
warning: squelched 14 whitespace errors
warning: 19 lines add whitespace errors.
Falling back to patching base and 3-way merge...
CONFLICT (delete/modify): sources/scalac/ast/LazyTreeFactory.java
deleted in HEAD and modified in Syntax changes for tuples and
sequences; symbols.. Version Syntax changes for tuples and sequences;
symbols. of sources/scalac/ast/LazyTreeFactory.java left in tree.
CONFLICT (delete/modify): sources/scalac/ast/Transformer.java deleted
in HEAD and modified in Syntax changes for tuples and sequences;
symbols.. Version Syntax changes for tuples and sequences; symbols. of
sources/scalac/ast/Transformer.java left in tree.
CONFLICT (delete/modify): sources/scalac/ast/Traverser.java deleted in
HEAD and modified in Syntax changes for tuples and sequences;
symbols.. Version Syntax changes for tuples and sequences; symbols. of
sources/scalac/ast/Traverser.java left in tree.
CONFLICT (delete/modify): sources/scalac/ast/Tree.java deleted in HEAD
and modified in Syntax changes for tuples and sequences; symbols..
Version Syntax changes for tuples and sequences; symbols. of
sources/scalac/ast/Tree.java left in tree.
CONFLICT (delete/modify): sources/scalac/ast/TreeCopyFactory.java
deleted in HEAD and modified in Syntax changes for tuples and
sequences; symbols.. Version Syntax changes for tuples and sequences;
symbols. of sources/scalac/ast/TreeCopyFactory.java left in tree.
CONFLICT (delete/modify): sources/scalac/ast/TreeCreator.java deleted
in HEAD and modified in Syntax changes for tuples and sequences;
symbols.. Version Syntax changes for tuples and sequences; symbols. of
sources/scalac/ast/TreeCreator.java left in tree.
CONFLICT (delete/modify): sources/scalac/ast/TreeFactory.java deleted
in HEAD and modified in Syntax changes for tuples and sequences;
symbols.. Version Syntax changes for tuples and sequences; symbols. of
sources/scalac/ast/TreeFactory.java left in tree.
CONFLICT (delete/modify): sources/scalac/ast/parser/Parser.java
deleted in HEAD and modified in Syntax changes for tuples and
sequences; symbols.. Version Syntax changes for tuples and sequences;
symbols. of sources/scalac/ast/parser/Parser.java left in tree.
CONFLICT (delete/modify): sources/scalac/ast/parser/Scanner.java
deleted in HEAD and modified in Syntax changes for tuples and
sequences; symbols.. Version Syntax changes for tuples and sequences;
symbols. of sources/scalac/ast/parser/Scanner.java left in tree.
CONFLICT (delete/modify): sources/scalac/ast/parser/Tokens.java
deleted in HEAD and modified in Syntax changes for tuples and
sequences; symbols.. Version Syntax changes for tuples and sequences;
symbols. of sources/scalac/ast/parser/Tokens.java left in tree.
CONFLICT (delete/modify):
sources/scalac/ast/printer/TextTreePrinter.java deleted in HEAD and
modified in Syntax changes for tuples and sequences; symbols.. Version
Syntax changes for tuples and sequences; symbols. of
sources/scalac/ast/printer/TextTreePrinter.java left in tree.
CONFLICT (delete/modify): sources/scalac/symtab/Definitions.java
deleted in HEAD and modified in Syntax changes for tuples and
sequences; symbols.. Version Syntax changes for tuples and sequences;
symbols. of sources/scalac/symtab/Definitions.java left in tree.
CONFLICT (delete/modify): sources/scalac/symtab/Modifiers.java deleted
in HEAD and modified in Syntax changes for tuples and sequences;
symbols.. Version Syntax changes for tuples and sequences; symbols. of
sources/scalac/symtab/Modifiers.java left in tree.
CONFLICT (delete/modify): sources/scalac/symtab/Symbol.java deleted in
HEAD and modified in Syntax changes for tuples and sequences;
symbols.. Version Syntax changes for tuples and sequences; symbols. of
sources/scalac/symtab/Symbol.java left in tree.
CONFLICT (delete/modify): sources/scalac/symtab/Type.java deleted in
HEAD and modified in Syntax changes for tuples and sequences;
symbols.. Version Syntax changes for tuples and sequences; symbols. of
sources/scalac/symtab/Type.java left in tree.
CONFLICT (delete/modify): sources/scalac/transformer/UnCurry.java
deleted in HEAD and modified in Syntax changes for tuples and
sequences; symbols.. Version Syntax changes for tuples and sequences;
symbols. of sources/scalac/transformer/UnCurry.java left in tree.
CONFLICT (delete/modify): sources/scalac/typechecker/Analyzer.java
deleted in HEAD and modified in Syntax changes for tuples and
sequences; symbols.. Version Syntax changes for tuples and sequences;
symbols. of sources/scalac/typechecker/Analyzer.java left in tree.
CONFLICT (delete/modify): sources/scalac/typechecker/DeSugarize.java
deleted in HEAD and modified in Syntax changes for tuples and
sequences; symbols.. Version Syntax changes for tuples and sequences;
symbols. of sources/scalac/typechecker/DeSugarize.java left in tree.
CONFLICT (delete/modify): sources/scalac/typechecker/Infer.java
deleted in HEAD and modified in Syntax changes for tuples and
sequences; symbols.. Version Syntax changes for tuples and sequences;
symbols. of sources/scalac/typechecker/Infer.java left in tree.
CONFLICT (delete/modify): sources/scalac/util/Names.java deleted in
HEAD and modified in Syntax changes for tuples and sequences;
symbols.. Version Syntax changes for tuples and sequences; symbols. of
sources/scalac/util/Names.java left in tree.
Failed to merge in the changes.
Patch failed at 0001 Syntax changes for tuples and sequences; symbols.
When you have resolved this problem run "git rebase --continue".
If you would prefer to skip this patch, instead run "git rebase --skip".
To restore the original branch and stop rebasing run "git rebase --abort".
On Thu, Dec 1, 2011 at 16:47, Daniel Sobral <dcsobral@gmail.com> wrote:
> On Thu, Dec 1, 2011 at 16:45, Daniel Spiewak <djspiewak@gmail.com> wrote:
>> Find corresponding commit hash in the new repo (no automation to help you
>> here)
>> git checkout <branch-based-on-commit-in-old-repo>
>> git rebase -i <commit-in-new-repo>
>> Triple check that everything went well
>
> Ah, ok. It doesn't work.
>
>>
>> I'm pretty sure it's also possible to rebase a specific chunk of commits on
>> top of another commit, I just can't remember the syntax for it right now.
>> man git-rebase is your friend. :-)
>>
>> Daniel
>>
>> On Thu, Dec 1, 2011 at 12:03 PM, Daniel Sobral <dcsobral@gmail.com> wrote:
>>>
>>> On Wed, Nov 30, 2011 at 18:57, Daniel Spiewak <djspiewak@gmail.com> wrote:
>>> > Note that it should be easy enough to adjust these pull requests so that
>>> > they work on top of the new repository. Basically, you need to do the
>>> > following. First, fix up the remote for the old scala repository so
>>> > that it
>>> > points to legacy-svn-scala (the easiest way to do this is to just edit
>>> > .git/config). Second, add a new remote for the new scala/scala
>>> > repository.
>>> > Fetch from that remote (do not pull). Now, make sure that each of your
>>> > pull
>>> > requests are in separate branches (they really should be anyway).
>>> > Checkout
>>> > those branches, then rebase them on top of the corresponding commits in
>>> > the
>>> > scala/master remote (where "scala" is assumed to be the remote name of
>>> > the
>>> > new scala/scala repository). This rebase should happen cleanly. Note
>>> > that
>>> > you may want to do rebase -i just to make sure that it doesn't pull in
>>> > any
>>> > redundant commits, but this shouldn't be necessary. Once each of your
>>> > commits is rebased, you can just `git remote rm` the legacy-svn remote
>>> > and
>>> > work exclusively with scala/scala. No commit redoing required!
>>>
>>> What exactly is the invocation for the rebase step? I always find that
>>> the position of parameters such as branch names are unintuitive, the
>>> intuitive one being the exact reverse, so I often commit stuff to
>>> master by mistake, and I'd prefer to avoid that.
>>>
>>> --
>>> Daniel C. Sobral
>>>
>>> I travel to the future all the time.
>>
>>
>
>
>
> --
> Daniel C. Sobral
>
> I travel to the future all the time.
>
--
Daniel C. Sobral
I travel to the future all the time.
Thu, 2011-12-01, 20:07
#4
Re: Re: Scala Github repository is now live
On 1 December 2011 20:00, Josh Suereth wrote:
> Another fall back for the lazy is "git diff master > patch.foo && git
> checkout new-master && git checkout -b new-branch && git apply patch.foo"
git format-patch and git am are better because they preserve commit
messsages, etc.
The easiest way to resolve conflicts is to just use git mergetool.
I think using format-patch, am and git mergetool is the easiest way to
migrate a small number of commits.
Thu, 2011-12-01, 20:27
#5
Re: Re: Scala Github repository is now live
Another fall back for the lazy is "git diff master > patch.foo && git checkout new-master && git checkout -b new-branch && git apply patch.foo"
This is actually what rebase is doing, except it's going to be smarter about things like whitespace and no-op commits. The above will work most of the time, but the conditions under which it works also allow rebase to work (and it's easier, and works under more conditions).
Daniel
Thu, 2011-12-01, 21:57
#6
Re: Re: Scala Github repository is now live
On 2011-12-01 17:11, Eugene Burmako wrote:
> Hey folks! How do you feel about removing ".project" and putting it
> under project.SAMPLE in the same fashion as it's done for
> ".classpath".
+1
> The motivation for that is that sometimes ".project" files are
> volatile. For example, if I want to create custom filters in Eclipse
> or want to disable Eclipse's Scala builder (and just use Ant), I need
> to modify ".project". But I don't want to commit those changes in
Note that you can create an Eclipse project (with all the meta-data
files) in a different location (e.g. the default workspace dir) and add
external ("linked") source folders that point to your working copy. (I
tried that today for working on the library but ran into a few issues
with the Scala editor and builder which may or may not be caused by this
setup. This needs some further investigation.)
-sz
Fri, 2011-12-02, 12:57
#7
Re: Re: Scala Github repository is now live
On Thursday 01 December 2011 08:11:46 Eugene Burmako wrote:
> The non-invasive solution to the problem might is making Git oblivious
> to the project file, but this doesn't work for me, since a record in
> my .gitignore doesn't prevent ".project" from being flagged as
> modified every time I want to commit. Your thoughts?
If you want git to ignore a file that is part of the repository, then you can
use "git update-index --assume-unchanged ".
Cheers,
Mirko
Hey folks! How do you feel about removing ".project" and putting it
under project.SAMPLE in the same fashion as it's done for
".classpath".
The motivation for that is that sometimes ".project" files are
volatile. For example, if I want to create custom filters in Eclipse
or want to disable Eclipse's Scala builder (and just use Ant), I need
to modify ".project". But I don't want to commit those changes in
order not to mess future pull requests into scala/scala. Also, I don't
want the ".project" file to show up as modified every time I do git
status or equivalent.
The non-invasive solution to the problem might is making Git oblivious
to the project file, but this doesn't work for me, since a record in
my .gitignore doesn't prevent ".project" from being flagged as
modified every time I want to commit. Your thoughts?