Discussion:
Some questions about fossil
(too old to reply)
Ramon Ribó
2009-10-04 10:42:35 UTC
Permalink
Dear list members,

We are currently using cvs to maintain many different projects in
our company. After reviewing fossil, it looks as a very nice piece of
software that can make a much better job than cvs for our development
needs. So, we are considering the possibility of moving into fossil
our current cvs repositories. If someone can help us in some/all of
the following questions, he will help us greatly in our decision.

1- I have been trying to use the tool cvs2fossil with a simple, few
files, no branches, small cvs project. For testing. Results:

a) changed tag branch ---> branch new in file c2f_fossil.tcl (this
error has been discussed in the list but is not corrected in the
trunk
b) If gpg signature is not defined for current user, it just fails,
does not give opportunity to say that signature is not desired
c) If project is inside a subdirectory inside cvsroot, it fails
when trying to create the repository file (can be fixed creating
manually the directory)
d) Once the repository is created, it works well from the browser
ui. Howerver, when doing a "fossil open ...", it fails and
answers: "fossil: object [1503758b20] is not a check-in". And
no file is created. What happens?

2- Why is it not possible to start a new fossil directory inside a
subdirectory of another fossil directory? This is a structure that we
use very often with cvs. I do not see the technical difficulties
for this. Just when descending or ascending the directories
hierarchy, if a _FOSSIL_ file is found, stop there

3- Why a single repository cannot contain several directories that can
be "fossil open ..." separately? It would have the
advantage of sharing the same users, wikis and tickets, but could
be checkout separately

4- The alternative to the previous point is to have many different
repositories in different fossil files. In that case, wouldn't be
interesting to have a simple way of transferring from one project
to another some/all of is attributes, like configuration options,
user management, wiki pages, etc.? It could range from a simple
import/export to a real synchronizing

5- How to make a gdiff of two repository versions (not a diff a
gdiff)? I've tried to make a gdiff of current version with a
repository version (the first chars of the sha of the version) , like
this:

fossil gdiff -r 55a6 tools/cvs2fossil/lib/c2f_fossil.tcl

and gives the error: fossil: no artifacts match the prefix "55a6"
where 55a6 is copied from the web browser as the prefix of the sha1
name identifying the version. What happens?

Thanks in advance for all the possible answers. It is important to
note that the import of cvs is crucial for us to decide to go to use
fossil

NOTE 2: As I am the author or RamDebugger, a debugger/IDE for TCL and
C/C++ that currently has cvs support, if we go ahead with fossil we
shall add support in RamDebugger for fossil. So, it would become a
graphical tool for dealing with the commits/updates/add/remove in
fossil.
D. Richard Hipp
2009-10-04 18:50:00 UTC
Permalink
Post by Ramon Ribó
2- Why is it not possible to start a new fossil directory inside a
subdirectory of another fossil directory? This is a structure that we
use very often with cvs. I do not see the technical difficulties
for this. Just when descending or ascending the directories
hierarchy, if a _FOSSIL_ file is found, stop there
Nested repositories seemed like fertile ground for growing
configuration management errors, so I disallowed it.
Post by Ramon Ribó
3- Why a single repository cannot contain several directories that can
be "fossil open ..." separately? It would have the
advantage of sharing the same users, wikis and tickets, but could
be checkout separately
Why not just check out the whole thing? What is the point of checking
out a partial tree? Are you really that short of disk space?
Post by Ramon Ribó
4- The alternative to the previous point is to have many different
repositories in different fossil files. In that case, wouldn't be
interesting to have a simple way of transferring from one project
to another some/all of is attributes, like configuration options,
user management, wiki pages, etc.? It could range from a simple
import/export to a real synchronizing
You can transfer user attributes and configuration options by doing
"fossil config export" from one repository then "fossil config import"
into another. This won't work for wiki, however, since wiki is
versioned and synced.
Post by Ramon Ribó
5- How to make a gdiff of two repository versions (not a diff a
gdiff)? I've tried to make a gdiff of current version with a
repository version (the first chars of the sha of the version) , like
fossil gdiff -r 55a6 tools/cvs2fossil/lib/c2f_fossil.tcl
and gives the error: fossil: no artifacts match the prefix "55a6"
where 55a6 is copied from the web browser as the prefix of the sha1
name identifying the version. What happens?
[55a6] is a file artifact. You want the version artifact:

fossil gdiff -r b7fc49d04 tools/cvs2fossil/lib/c2f_fossil.tcl

D. Richard Hipp
***@hwaci.com
Ramon Ribó
2009-10-04 19:54:38 UTC
Permalink
Why not just check out the whole thing?  What is the point of checking
out a partial tree?  Are you really that short of disk space?
Of course, this is not a disk space issue. There are several reasons to
consider it as an advantage:

- Some packages are developed by some developers but not by others

- Packages are located in the disk in some part of a global project

- The location of the packages in the disk depends on that the packages
are developed and used at the same time (think on TCL packages)
    fossil gdiff -r b7fc49d04 tools/cvs2fossil/lib/c2f_fossil.tcl
fossil gdiff -r b7fc49d04 tools/cvs2fossil/lib/c2f_fossil.tcl
fossil: no artifacts match the prefix "b7fc49d04"

(this is executed in the main fossil directory of the fossil source)

You have no comments on cvs2fossil. Should we completely discard the
use of this tool or can we have reasonable expectations that it will
be made usable in the future?
Ramon Ribó
2009-10-07 16:01:43 UTC
Permalink
1- If someone wants to create a new cvs2fossil, what command can be
used to commit a
file with an ancient date?

2- How to revert a file to a different version but saving with a
different name?
D. Richard Hipp
2009-10-07 16:16:50 UTC
Permalink
Post by Ramon Ribó
1- If someone wants to create a new cvs2fossil, what command can be
used to commit a
file with an ancient date?
Use undocumented flags to commit:

--date-override 2009-10-06T12:34:56
--user-override userid
Post by Ramon Ribó
2- How to revert a file to a different version but saving with a
different name?
You can use the web interface to download any version of any file you
want. Your web browser will normally let you choose the name.

From the command-line, you can try using the "test-content-get"
command:

fossil test-content-get SHA1-hash-of-file output-filename
Post by Ramon Ribó
_______________________________________________
fossil-users mailing list
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
D. Richard Hipp
***@hwaci.com
Andreas Kupries
2009-10-07 16:35:48 UTC
Permalink
Post by D. Richard Hipp
Post by Ramon Ribó
1- If someone wants to create a new cvs2fossil, what command can be
used to commit a
file with an ancient date?
--date-override 2009-10-06T12:34:56
--user-override userid
Oh. I didn't know about these (while writing cvs2fossil). Which is why I put
this information into the new commit message. Since when do they exist ?
--
Sincerely,
Andreas Kupries <***@activestate.com>
Developer @ <http://www.activestate.com/>
Ramon Ribó
2009-10-07 16:43:24 UTC
Permalink
Post by Andreas Kupries
Oh. I didn't know about these (while writing cvs2fossil). Which is why I put
this information into the new commit message. Since when do they exist ?
Andreas, I see that you are the developer of cvs2fossil. I have tried it and I
have had some problems with it (the details are in another message). Might we
have some expectations that it will work in the future or is it better
that we develop
our own solutions for converting from cvs to fossil?
Andreas Kupries
2009-10-07 16:54:30 UTC
Permalink
Post by Ramon Ribó
Post by Andreas Kupries
Oh. I didn't know about these (while writing cvs2fossil). Which is why I put
this information into the new commit message. Since when do they exist ?
Andreas, I see that you are the developer of cvs2fossil. I have tried it and I
have had some problems with it (the details are in another message).
Is it possible to send me this message ? It seems that I missed it. As such I
do not know (yet) what you are talking about.
Post by Ramon Ribó
Might we
have some expectations that it will work in the future
Not really possible to answer this with specificity without knowing what the
actual problems are. Only in general, the easier to understand the problem and
making a fix, the better the chances of me doing it.

General side note: The cvs2svn application (written in python) is the spiritual
ancestor of cvs2fossil (*). As such it would be an interesting comparison to
see if whatever CVS repository is giving you trouble with cvs2fossil is giving
cvs2svn (similar) trouble as well.

(*) I used the general architectural concepts (phases and object classes),
and basic information they had unearthed about revision(number)s,
things to do, etc., while writing my stuff from scratch using a nicer
persistent data store (sqlite instead of their flat text files, pickled
python objects, and the like).
Post by Ramon Ribó
or is it better
that we develop
our own solutions for converting from cvs to fossil?
What about the third option ? I.e. editing cvs2fossil instead of developing
from scratch ?
--
Sincerely,
Andreas Kupries <***@activestate.com>
Developer @ <http://www.activestate.com/>
Ramon Ribó
2009-10-07 17:51:15 UTC
Permalink
Andreas,

The problems were:

1- I have been trying to use the tool cvs2fossil with a simple, few
files, no branches, small cvs project. For testing. Results:

a) changed tag branch ---> branch new in file c2f_fossil.tcl (this
error has been discussed in the list but is not corrected in the
trunk
b) If gpg signature is not defined for current user, it just fails,
does not give opportunity to say that signature is not desired
c) If project is inside a subdirectory inside cvsroot, it fails
when trying to create the repository file (can be fixed creating
manually the directory)
d) Once the repository is created, it works well from the browser
ui. Howerver, when doing a "fossil open ...", it fails and
answers: "fossil: object [1503758b20] is not a check-in". And
no file is created. What happens?

a) b) and c) should be easy to fix. Point d) I have no idea what
happens.
Post by Andreas Kupries
Post by Andreas Kupries
Oh. I didn't know about these (while writing cvs2fossil). Which is why I put
this information into the new commit message. Since when do they exist ?
  Andreas, I see that you are the developer of cvs2fossil. I have tried it and I
have had some problems with it (the details are in another message).
Is it possible to send me this message ? It seems that I missed it. As such I
do not know (yet) what you are talking about.
 > Might we
have some expectations that it will work in the future
Not really possible to answer this with specificity without knowing what the
actual problems are. Only in general, the easier to understand the problem and
making a fix, the better the chances of me doing it.
General side note: The cvs2svn application (written in python) is the spiritual
ancestor of cvs2fossil (*). As such it would be an interesting comparison to
see if whatever CVS repository is giving you trouble with cvs2fossil is giving
cvs2svn (similar) trouble as well.
(*)     I used the general architectural concepts (phases and object classes),
       and basic information they had unearthed about revision(number)s,
       things to do, etc., while writing my stuff from scratch using a nicer
       persistent data store (sqlite instead of their flat text files, pickled
       python objects, and the like).
 > or is it better
that we develop
our own solutions for converting from cvs to fossil?
What about the third option ? I.e. editing cvs2fossil instead of developing
from scratch ?
--
Sincerely,
_______________________________________________
fossil-users mailing list
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
Andreas Kupries
2009-10-07 18:11:39 UTC
Permalink
Post by Ramon Ribó
Andreas,
Thanks.
Post by Ramon Ribó
1- I have been trying to use the tool cvs2fossil with a simple, few
a) changed tag branch ---> branch new in file c2f_fossil.tcl (this
error has been discussed in the list but is not corrected in the
trunk
This looks to be a trivial change. Assuming that the syntax is similar.
discussed on the list ... Ok, will dive into my mail archives to see if I can
find this again ...
Post by Ramon Ribó
b) If gpg signature is not defined for current user, it just fails,
does not give opportunity to say that signature is not desired
What is the command line you invoked cvs2fossil with ?
In which phase of cvs2fossil does it fail ?
What is the error message ?
Post by Ramon Ribó
c) If project is inside a subdirectory inside cvsroot, it fails
when trying to create the repository file (can be fixed creating
manually the directory)
When you say cvsroot, are you talking about the top directory of your test
repository, or the administrative directory named 'CVSROOT' inside of it ?

What is the command line you invoked cvs2fossil with ?
In which phase of cvs2fossil does it fail ?
What is the error message you see ?
Post by Ramon Ribó
d) Once the repository is created, it works well from the browser
ui. Howerver, when doing a "fossil open ...", it fails and
answers: "fossil: object [1503758b20] is not a check-in". And
no file is created. What happens?
That seems to be the biggest problem, and seems to indicate that a bad
repository was generated. I have not seen such a message before and do not know
what it signifies. This one will require serious source diving in fossil itself
to understand what it is complaining about before I can even try to understand
what cvs2fossil is doing wrong.
Post by Ramon Ribó
a) b) and c) should be easy to fix.
Tentatively agreed, and assuming I get more information about the problem, per
my questions above.

Best might be to give me both the command line you use, and the CVS repository
you are working with. I do not know however if the latter is something you can
(are allowed to) hand out outside of your company or organization.
Post by Ramon Ribó
Point d) I have no idea what
happens.
Me neither, at this point.
--
Sincerely,
Andreas Kupries <***@activestate.com>
Developer @ <http://www.activestate.com/>
Ramon Ribó
2009-10-08 09:35:05 UTC
Permalink
Andreas,

I have tried several projects and all of them fail, with different
errors. Have you managed to import any cvs repository with current
fossil sources?

PS: Unfortunately, the cvs repository cannot be disclosed.


----
Compass Ing. y Sistemas Dr. Ramon Ribo
http://www.compassis.com ***@compassis.com
c/ Tuset, 8 7-2 tel. +34 93 218 19 89
08006 Barcelona, Spain fax. +34 93 396 97 46
Post by Andreas Kupries
  Andreas,
Thanks.
1- I have been trying to use the tool cvs2fossil with a simple, few
   a) changed tag branch  ---> branch new in file c2f_fossil.tcl (this
error has been discussed in the list but is not corrected in the
       trunk
This looks to be a trivial change. Assuming that the syntax is similar.
discussed on the list ... Ok, will dive into my mail archives to see if I can
find this again ...
   b) If gpg signature is not defined for current user, it just fails,
does not give opportunity to say that signature is not desired
What is the command line you invoked cvs2fossil with ?
In which phase of cvs2fossil does it fail ?
What is the error message ?
   c) If project is inside a subdirectory inside cvsroot, it fails
when trying to create the repository file (can be fixed creating
       manually the directory)
When you say cvsroot, are you talking about the top directory of your test
repository, or the administrative directory named 'CVSROOT' inside of it ?
What is the command line you invoked cvs2fossil with ?
In which phase of cvs2fossil does it fail ?
What is the error message you see ?
   d) Once the repository is created, it works well from the browser
ui. Howerver, when doing a "fossil open ...", it fails and
       answers: "fossil: object [1503758b20] is not a check-in". And
no file is created. What happens?
That seems to be the biggest problem, and seems to indicate that a bad
repository was generated. I have not seen such a message before and do not know
what it signifies. This one will require serious source diving in fossil itself
to understand what it is complaining about before I can even try to understand
what cvs2fossil is doing wrong.
a) b) and c) should be easy to fix.
Tentatively agreed, and assuming I get more information about the problem, per
my questions above.
Best might be to give me both the command line you use, and the CVS repository
you are working with. I do not know however if the latter is something you can
(are allowed to) hand out outside of your company or organization.
 > Point d) I have no idea what
happens.
Me neither, at this point.
--
Sincerely,
_______________________________________________
fossil-users mailing list
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
Andreas Kupries
2009-10-08 17:06:11 UTC
Permalink
Post by Ramon Ribó
Andreas,
I have tried several projects and all of them fail, with different
errors. Have you managed to import any cvs repository with current
fossil sources?
I haven't run cvs2fossil for quite some time now.
Post by Ramon Ribó
PS: Unfortunately, the cvs repository cannot be disclosed.
A pity. Not a big surprise tough.

That said, disclosure of the command line invocations you used, and of log
output / error messages / stack traces returned, should be possible IMHO, and
would be of help too. Regarding the log output, a high logging level would be
appreciated. I.e. I consider it better to have too much output that I have to
(but can) pare down, than not enough.

The default log level is 2, each additional use of '-v' on the command line
cranks the level up by one, and the max log level I used in the whole code is
15. This can generate multi-megabyte sized logs however. Should be highly
compressible tough.

Please send this information to my home address, i.e. <***@shaw.ca>.
This is not something I can do at the office.
Post by Ramon Ribó
Post by Ramon Ribó
a) changed tag branch ---> branch new in file c2f_fossil.tcl (this
error has been discussed in the list but is not corrected in the
trunk
Hm, the phrasing seems to imply that you did this change, right ?
If so, please send the patch / undified diff you have.
--
Sincerely,
Andreas Kupries <***@activestate.com>
Developer @ <http://www.activestate.com/>
Daniel Clark
2009-10-07 19:49:13 UTC
Permalink
Post by Andreas Kupries
What about the third option ? I.e. editing cvs2fossil instead of developing
from scratch ?
Another option: write fossil support for tailor -
http://progetti.arstecnica.it/tailor - which would give migration
support to a large number of other VCS / DVCS types.

(which would also have the nice side benefit of making
http://sscm.masukomi.org/ work)
--
Daniel JB Clark | Sys Admin, Free Software Foundation
pobox.com/~dclark | http://www.fsf.org/about/staff#danny
Daniel Clark
2009-10-07 19:49:13 UTC
Permalink
Post by Andreas Kupries
What about the third option ? I.e. editing cvs2fossil instead of developing
from scratch ?
Another option: write fossil support for tailor -
http://progetti.arstecnica.it/tailor - which would give migration
support to a large number of other VCS / DVCS types.

(which would also have the nice side benefit of making
http://sscm.masukomi.org/ work)
--
Daniel JB Clark | Sys Admin, Free Software Foundation
pobox.com/~dclark | http://www.fsf.org/about/staff#danny
Rene de Zwart
2009-10-07 20:57:48 UTC
Permalink
I wonder what the sequence is for importing cvs files into fossil. I tried
to get it from cvs2fossil but got lost.

first you need to get a commit identifier?
assume the following cvs-repository 'example'
first.c with rev 1.1 1.2 1.3 1.4
second.c with rev 1.1 1.2 1.3 1.4 and only one user user1

commit 1 first.c rev 1.1

commit 2 first.c rev 1.2 second.c rev 1.1

commit 3 first.c rev 1.3 second.c rev 1.2

commit 4 second.c rev 1.3

commit 5 first.c rev 1.4 second.c 1.4

cvs2fossil does
create repository 'example' with user1?
then
first.c rev 1.1 1.2 1.3 1.4
and then
second.c rev 1.1 1.2 1.3 1.4

which test-? are used to accomplish this?

Rene
Post by D. Richard Hipp
Post by Ramon Ribó
1- If someone wants to create a new cvs2fossil, what command can be
used to commit a
file with an ancient date?
--date-override 2009-10-06T12:34:56
--user-override userid
Post by Ramon Ribó
2- How to revert a file to a different version but saving with a
different name?
You can use the web interface to download any version of any file you
want. Your web browser will normally let you choose the name.
Andreas Kupries
2009-10-07 23:27:13 UTC
Permalink
Post by Rene de Zwart
I wonder what the sequence is for importing cvs files into fossil. I tried
to get it from cvs2fossil but got lost.
first you need to get a commit identifier?
assume the following cvs-repository 'example'
first.c with rev 1.1 1.2 1.3 1.4
second.c with rev 1.1 1.2 1.3 1.4 and only one user user1
commit 1 first.c rev 1.1
commit 2 first.c rev 1.2 second.c rev 1.1
commit 3 first.c rev 1.3 second.c rev 1.2
commit 4 second.c rev 1.3
commit 5 first.c rev 1.4 second.c 1.4
cvs2fossil does
create repository 'example' with user1?
then
first.c rev 1.1 1.2 1.3 1.4
and then
second.c rev 1.1 1.2 1.3 1.4
which test-? are used to accomplish this?
See file
c2f_fossil.tcl

That contains the code exec'ing fossil.
Look for the 'Do ...' calls.

cvs2fossil basically imports the files first, by revision, using some test-
commands to setup the delta-chain. Then it uses some more test- commands to
import the changesets, i.e. sets of file revisions.
--
Sincerely,
Andreas Kupries <***@activestate.com>
Developer @ <http://www.activestate.com/>
Andreas Kupries
2009-10-07 23:30:04 UTC
Permalink
Post by Andreas Kupries
See file
c2f_fossil.tcl
That contains the code exec'ing fossil.
Look for the 'Do ...' calls.
cvs2fossil basically imports the files first, by revision, using some test-
commands to setup the delta-chain. Then it uses some more test- commands to
import the changesets, i.e. sets of file revisions.
Another trick useful in such circumstances:

mv fossil __fossil

echo <<"eof"
#!/bin/sh
echo fossil $* > /your/log/file
__fossil $*
"eof" > fossil

Essentially create a shell script wrapper around the application which logs the
invokations and their arguments.
--
Sincerely,
Andreas Kupries <***@activestate.com>
Developer @ <http://www.activestate.com/>
Rene de Zwart
2009-10-08 13:50:10 UTC
Permalink
Post by Andreas Kupries
Post by Andreas Kupries
See file
c2f_fossil.tcl
That contains the code exec'ing fossil.
Look for the 'Do ...' calls.
cvs2fossil basically imports the files first, by revision, using some test-
commands to setup the delta-chain. Then it uses some more test- commands to
import the changesets, i.e. sets of file revisions.
mv fossil __fossil
echo <<"eof"
#!/bin/sh
echo fossil $* >> /your/log/file
rc=`__fossil $*`
echo $rc >> /your/log/file
echo $rc
Post by Andreas Kupries
"eof" > fossil
Essentially create a shell script wrapper around the application which logs the
invokations and their arguments.
--
Sincerely,
_______________________________________________
fossil-users mailing list
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
Andreas Kupries
2009-10-08 16:47:53 UTC
Permalink
Post by Rene de Zwart
Post by Andreas Kupries
Post by Andreas Kupries
See file
c2f_fossil.tcl
#!/bin/sh
echo fossil $* >> /your/log/file
rc=`__fossil $*`
echo $rc >> /your/log/file
echo $rc
Right, the result of the command can be of interest too.
And the $? variable should hold the exit status of the app after the call.

Note. We assumed a basic bourne sh here. If the shell is a bash we can use

rc=$(__fossil $*)

instead of the backticks. More readable, nestable, better structured.
--
Sincerely,
Andreas Kupries <***@activestate.com>
Developer @ <http://www.activestate.com/>
Rene de Zwart
2009-10-08 17:29:14 UTC
Permalink
Post by Andreas Kupries
Post by Rene de Zwart
Post by Andreas Kupries
Post by Andreas Kupries
See file
c2f_fossil.tcl
#!/bin/sh
echo fossil $* >> /your/log/file
rc=`__fossil $*`
echo $rc >> /your/log/file
echo $rc
Right, the result of the command can be of interest too.
And the $? variable should hold the exit status of the app after the call.
Note. We assumed a basic bourne sh here. If the shell is a bash we can use
rc=$(__fossil $*)
instead of the backticks. More readable, nestable, better structured.
--
Sincerely,
_______________________________________________
fossil-users mailing list
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
there is one slight problem ;-)

fossil get feed with
fossil test-import-manifest 1255003794 By renez: example repostory -f
2 example/first

instead of
fossil test-import-manifest 1255003794 "By renez: example repostory"
-f 2 example/first

I suppose there is a newline between user: and Comment. It is in
c2f_fossil.tcl. I see no parsing of the comment in checkin.c.
Does the cvs commiter get named in fossil? I get the impression that every
thing is filed under the user who does the conversion.

But it is insightful. How on earth did you figured these things out?

Rene
Andreas Kupries
2009-10-08 17:39:51 UTC
Permalink
This post might be inappropriate. Click to display it.
Continue reading on narkive:
Loading...