Re: [fossil-users] Fossil svn conversion gets confused if last svn checkin is on a branch

2013-02-22 Thread Warren Young

On 2/22/2013 14:09, Warren Young wrote:


"trunk" would be a good
default if Fossil had a "training wheels" mode for newbies like me, but
I can't seriously propose that as a feature.


Thinking more about it, this is really a Subversion issue.  Unlike Git 
and Fossil, svn lets you create a branch of a subtree within the 
repository.


If you start work on a fresh Fossil repo without importing anything, or 
if you started with Git and imported into Fossil, you can't get into the 
confused state I fell into.  Even if the last checkin is on some minor 
sub-branch, you're still going to see the complete top-level project 
directory structure, as of that branch point anyway.


It makes me wonder which other VCSes allow partial tree branches. 
Wikipedia's comparison page[1] doesn't say.


[1] http://goo.gl/KQX5s
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] Fossil svn conversion gets confused if last svn checkin is on a branch

2013-02-22 Thread Warren Young

On 2/21/2013 02:03, Martijn Coppoolse wrote:

This sounds as if the 'Files' tab of your repository links to

   http:dir?ci=tip

whereas you expected it to link to

   http:dir?ci=trunk


Yep, you've nailed it.

"tip" is the out-of-the-box default on a fresh repo, and seems to be a 
sensible default for day-to-day use of Fossil.  "trunk" would be a good 
default if Fossil had a "training wheels" mode for newbies like me, but 
I can't seriously propose that as a feature.


I suppose it's best if text talking about repository conversions 
mentions this potential surprise.

___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] Fossil svn conversion gets confused if last svn checkin is on a branch

2013-02-21 Thread Martijn Coppoolse

On 20-2-2013 22:34, Warren Young wrote:

But before looking at it, I want to stress that I don't believe Fossil
has lost any data, it's just that the default Files view shows the last
branch I worked on, rather than the trunk as I expected.


This sounds as if the 'Files' tab of your repository links to

  http:dir?ci=tip

whereas you expected it to link to

  http:dir?ci=trunk


'tip' is an alias for the most recent check-in.  If your most recent 
check-in was not in trunk, you won’t see trunk on that page.


You can easily adjust that in the Admin/Header section of the web interface.

--
Martijn Coppoolse


___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] Fossil svn conversion gets confused if last svn checkin is on a branch

2013-02-20 Thread Warren Young

On 2/20/2013 14:25, Richard Hipp wrote:

If you will send me the output of "git fast-export -all"


It's below.

But before looking at it, I want to stress that I don't believe Fossil 
has lost any data, it's just that the default Files view shows the last 
branch I worked on, rather than the trunk as I expected.  Fossil *does* 
seem to know which branch is which, and they contain the correct files. 
 It seems more a case of a confusing default than actual confusion 
within Fossil proper.


Anyway, here 'tis:

$ git fast-export --all
blob
mark :1
data 0

reset refs/remotes/bug@2
commit refs/remotes/bug@2
mark :2
author Warren Young  1361393847 +
committer Warren Young  1361393847 +
data 13
added files

M 100644 :1 c
M 100644 :1 d

commit refs/remotes/bug
mark :3
author Warren Young  1361393881 +
committer Warren Young  1361393881 +
data 21
showing the bug now

from :2

reset refs/heads/master
commit refs/heads/master
mark :4
author Warren Young  1361393786 +
committer Warren Young  1361393786 +
data 9
initial


commit refs/heads/master
mark :5
author Warren Young  1361393847 +
committer Warren Young  1361393847 +
data 13
added files

from :4
M 100644 :1 one/a
M 100644 :1 one/b
M 100644 :1 two/c
M 100644 :1 two/d

reset refs/heads/master
from :5

reset refs/remotes/trunk
from :5

___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] Fossil svn conversion gets confused if last svn checkin is on a branch

2013-02-20 Thread Warren Young

On 2/20/2013 13:30, Themba Fletcher wrote:


Does the following help in your case?

tif@:~$ fossil help settings | grep main-branch
main-branch  The primary branch for the project.  Default: trunk


No, sorry.

It makes sense that it doesn't help.  If I open the minimal testcase 
repository I just sent to the list then say "fossil set" from within 
that checkout directory, I don't see an override of this setting within 
the repository.  Therefore, Fossil isn't getting the setting this way.


If I look at the setting in Fossil UI via Admin/Settings, I see "trunk", 
not "bug", as you'd expect if the problem were Fossil believing "bug" is 
the trunk.


Now that I play with it more, I can see that the "trunk" branch is 
available from the Branches tab, and it shows all files.  So, it's not 
that Fossil doesn't know which branch is which, it's that its Files view 
is defaulting to show the last thing worked on, or something.


Regardless, it's confusing.
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] Fossil svn conversion gets confused if last svn checkin is on a branch

2013-02-20 Thread Richard Hipp
On Wed, Feb 20, 2013 at 4:20 PM, Warren Young  wrote:

> On 2/19/2013 21:07, Warren Young wrote:
>
>>
>> We eventually figured out that Fossil was getting confused by the fact
>> that the last svn checkin was on a branch instead of the trunk, and that
>> branch held the file subset we saw in the Fossil Files tab.
>>
>
> I've got a minimal testcase.  The resulting scrubbed repository is
> attached, but you can recreate it easily like so:
>
>   $ svnadmin create /svn/fossil-branch-confusion
>   $ mkdir -p tmpsvn/branches tmpsvn/tags tmpsvn/trunk
>   $ svn import tmpsvn file:///svn/fossil-branch-**confusion
>   $ rm -r tmpsvn
>   $ svn co file:///svn/fossil-branch-**confusion/trunk tmpsvn
>   $ cd tmpsvn
>   $ mkdir one two
>   $ touch one/a one/b
>   $ touch two/c two/d
>   $ svn add *
>   $ svn ci -m "initial"
>   $ svn cp -m "bug" two file:///svn/fossil-branch-**confusion/branches/bug
>   $ cd ..
>   $ git svn clone -qs --no-metadata --authors-file=../authors.txt \
> file:///svn/fossil-branch-**confusion tmpgit
>   $ cd tmpgit
>

If you will send me the output of "git fast-export -all" then I can check
to see if this is really a problem with Fossil or a problem in
git-fast-exports (which does have its share of problems) or perhaps
something else.


>   $ git fast-export --all | fossil import ../branch-confusion.fossil
>   $ fossil serve ../branch-confusion.fossil
>
> Notice that the Files tab shows only the 'c' and 'd' files from the branch
> created about 2/3 the way through that command series.  If you then go back
> and make a change (say, adding a line to one/a) and check it into the svn
> repo, it will go into the trunk and a subsequent reconversion to Fossil via
> Git will result in 'one' and 'two' being at the top level of the Files tab.
>
> ___
> fossil-users mailing list
> fossil-users@lists.fossil-scm.org
> http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
>
>


-- 
D. Richard Hipp
d...@sqlite.org
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] Fossil svn conversion gets confused if last svn checkin is on a branch

2013-02-20 Thread Themba Fletcher
On Tue, Feb 19, 2013 at 8:07 PM, Warren Young  wrote:
>

>
> The request, of course, is for the Fossil Git importer to either have some
> improvement that makes it smarter about recognizing the *true* trunk, or at
> least a flag that lets you tell it the trunk's tag name if it guesses wrong.
>

Does the following help in your case?

tif@:~$ fossil help settings | grep main-branch
   main-branch  The primary branch for the project.  Default: trunk
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


[fossil-users] Fossil svn conversion gets confused if last svn checkin is on a branch

2013-02-19 Thread Warren Young
I'm currently working through the conversion of a 14 year old (!) svn 
repo to Fossil, and ran into dodgy behavior in one of the iterations.


Over the years, we've changed how we named branches and tags a few 
times.  We had a mess like this:


mms5_00
mms6.3
mms-7.0
mms-v8

Dash or no dash, 'v' or no 'v', underscores vs dots...

We can more easily ignore messes like this with svn than with Fossil, 
since you have to go poking around in the "branches" subdirectory to see 
it in svn, whereas in Fossil, it's right there in the main UI.


So, we decided to clean these up in svn before converting to Fossil, 
since Fossil seems more aggressive about preserving history, no matter 
how distasteful.  We did a bunch of


svn mv file:///svn/branches/mms6.3 file:///svn/branches/mms-6.3

type stuff, then spent the 2 hours to convert the repo again.

On looking at the Files tab in the Fossil UI after conversion, we saw 
that we only had a subset of the original repo files!  Yet, the .fossil 
DB file was the same size as with the previous conversion, so clearly we 
didn't actually lose anything.


We eventually figured out that Fossil was getting confused by the fact 
that the last svn checkin was on a branch instead of the trunk, and that 
branch held the file subset we saw in the Fossil Files tab.


We fixed that by doing one last bogus checkin on the svn repo trunk, 
completely redid the conversion (another 2 hours), and now Fossil is 
showing the correct directory structure in the Files tab.


The request, of course, is for the Fossil Git importer to either have 
some improvement that makes it smarter about recognizing the *true* 
trunk, or at least a flag that lets you tell it the trunk's tag name if 
it guesses wrong.


By the way, you might be realizing that Fossil would now be showing both 
"mms6.3" and "mms-6.3" branches after my "svn mv" command above.  But, 
we've fixed that with Git's history rewriting abilities, since we have 
to use it as an intermediary anyway.  The two branches are pure aliases 
for one another, so there's no harm removing the one with the obsolete 
version naming scheme, right?

___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users