Re: [fossil-users] Parent of the very first checkin?

2013-12-21 Thread Andy Bradford
Thus said Stephan Beal on Sat, 21 Dec 2013 10:30:57 +0100:

> [stephan@host:~/cvs/fossil/fossil]$ echo 'select uuid from blob order by
> rid limit 1;' | f sqlite3
> a28c83647dfa805f05f3204a7e146eb1f0d90505

Ok, I assumed it would involve finding the first rid, but wasn't certain
that this was right.

Thanks,

Andy
-- 
TAI64 timestamp: 400052b5cb34


___
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] Parent of the very first checkin?

2013-12-21 Thread j. van den hoff
On Sat, 21 Dec 2013 05:54:24 +0100, Andy Bradford  
 wrote:



Thus said Richard Hipp on Fri, 20 Dec 2013 19:05:07 -0500:


http://www.fossil-scm.org/fossil/info/a28c83647d


Is there a  command line option that will find  this artifact? I thought
perhaps the root:trunk symbolic name would  find it, but I was wrong. It
finds c06edd231fc15d145a1c96c39b8fecdb79b33523 which is apparently where
the current trunk began from a branch.

Of course  the following  works, but I  have to guess  at the  number of
artifacts:

fossil timeline -n 10 | tail


actually, you don't need to guess any more since `n 0' now yields so whole  
timeline. so


fossil timeline -n 0 |tail -2 | awk -F[][] 'NR == 1 {print $2}'

should yield the SHA1 hash of initial checkin (for recent versions of  
`fossil' emitting the trailing `+++ end of timeline (10587) +++' message).


but I just think (repeat it until it sticks ;-):  
http://en.wikipedia.org/wiki/Carthago_delenda_est) this is another  
instance where fossil would profit from supporting incremental revision  
numbers in the respective local repo so that one could just update to  
revision no. 0.


j.



Thanks,

Andy



--
Using Opera's revolutionary email client: http://www.opera.com/mail/
___
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] Parent of the very first checkin?

2013-12-21 Thread David Given
On 21/12/13 09:30, Stephan Beal wrote:
> select uuid from blob order by
> rid limit 1;

Oh, hadn't thought of that. Very nice.

I'm writing a script to manipulate someone else's repository, so tagging
it myself isn't an option --- I have to work with default functionality
only.

Right now I'm using the 'fossil json' API but it's missing a couple of
things (tag values in the timeline, event timeline). I might switch to
raw SQL.

-- 
┌─── dg@cowlark.com ─ http://www.cowlark.com ─
│ "There does not now, nor will there ever, exist a programming
│ language in which it is the least bit hard to write bad programs." ---
│ Flon's Axiom



signature.asc
Description: OpenPGP digital signature
___
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] Parent of the very first checkin?

2013-12-21 Thread Jan Nijtmans
2013/12/21 Stephan Beal :
> On Sat, Dec 21, 2013 at 5:54 AM, Andy Bradford 
> wrote:
>>
>> perhaps the root:trunk symbolic name would  find it, but I was wrong. It
>> finds c06edd231fc15d145a1c96c39b8fecdb79b33523 which is apparently where
>> the current trunk began from a branch.
>
>
> Here's a workaround:
>
> [stephan@host:~/cvs/fossil/fossil]$ echo 'select uuid from blob order by rid
> limit 1;' | f sqlite3
> a28c83647dfa805f05f3204a7e146eb1f0d90505
>

Simpler and somewhat dangerous (there is no guarantee that
the first check-in will actually have rid=1):

   fossil update rid:1

You could also tag the first initial checking with anything
you like, then you can use that tag in the future:

   fossil tag add "mother" rid:1
   fossil update mother

Regards,
 Jan Nijtmans
___
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] Parent of the very first checkin?

2013-12-21 Thread Stephan Beal
On Sat, Dec 21, 2013 at 5:54 AM, Andy Bradford wrote:

> perhaps the root:trunk symbolic name would  find it, but I was wrong. It
> finds c06edd231fc15d145a1c96c39b8fecdb79b33523 which is apparently where
> the current trunk began from a branch.
>

Here's a workaround:

[stephan@host:~/cvs/fossil/fossil]$ echo 'select uuid from blob order by
rid limit 1;' | f sqlite3
a28c83647dfa805f05f3204a7e146eb1f0d90505

[stephan@host:~/cvs/fossil/fossil]$ f artifact
a28c83647dfa805f05f3204a7e146eb1f0d90505
C initial\sempty\sbaseline
D 2007-07-21T14:09:59
P
R d41d8cd98f00b204e9800998ecf8427e
U drh
Z c62e3619f7c41ee77b33f00df8ec26f4


-- 
- stephan beal
http://wanderinghorse.net/home/stephan/
http://gplus.to/sgbeal
"Freedom is sloppy. But since tyranny's the only guaranteed byproduct of
those who insist on a perfect world, freedom will have to do." -- Bigby Wolf
___
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] Parent of the very first checkin?

2013-12-20 Thread Matt Welland
How is what you are looking for different from checking out the very first
node in your tree, the "initial empty check-in"?

I used to do what you are describing quite extensively when I used
monotone. But with monotone it was easy to sync a subset of branches or
revision trees from one repo to another. In fossil this is not possible.
Once the multiple revision trees are in the same repo they cannot be
separated using native tools. You could conceivably export and separate in
some other tool I suppose. Anyhow, this factor made it impractical for me
to keep different trees in the same repo. I'd be curious to hear a
description of your methodology.




On Fri, Dec 20, 2013 at 4:23 PM, David Given  wrote:

> hg has a concept of the changeset with uuid
> . This is the empty changeset,
> and is equivalent to the parent of the very first checkin. Checking out
> this changeset will give you an empty repository; checking in with this
> as the parent will give you a new tree, not connected to the old one.
>
> I find myself needing to do this in Fossil: both as something I can
> check out to remove all files from the working directory, and something
> I can use as a parent so I can create multiple revision trees.
>
> AFAIK there's nothing in the Fossil architecture to forbid it --- is
> there any way I can do this?
>
> --
> ┌─── dg@cowlark.com ─ http://www.cowlark.com ─
> │ "There does not now, nor will there ever, exist a programming
> │ language in which it is the least bit hard to write bad programs." ---
> │ Flon's Axiom
>
>
> ___
> fossil-users mailing list
> fossil-users@lists.fossil-scm.org
> http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
>
>


-- 
Matt
-=-
90% of the nations wealth is held by 2% of the people. Bummer to be in the
majority...
___
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] Parent of the very first checkin?

2013-12-20 Thread B Harder
If I understand what you're looking for (first empty commit?), when I asked
this question some time ago, somebody suggested I just tag it myself.
Simple solution, Just Works.
On Dec 20, 2013 8:54 PM, "Andy Bradford"  wrote:

> Thus said Richard Hipp on Fri, 20 Dec 2013 19:05:07 -0500:
>
> > http://www.fossil-scm.org/fossil/info/a28c83647d
>
> Is there a  command line option that will find  this artifact? I thought
> perhaps the root:trunk symbolic name would  find it, but I was wrong. It
> finds c06edd231fc15d145a1c96c39b8fecdb79b33523 which is apparently where
> the current trunk began from a branch.
>
> Of course  the following  works, but I  have to guess  at the  number of
> artifacts:
>
> fossil timeline -n 10 | tail
>
> Thanks,
>
> Andy
> --
> TAI64 timestamp: 400052b51f20
>
>
> ___
> fossil-users mailing list
> fossil-users@lists.fossil-scm.org
> http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
>
___
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] Parent of the very first checkin?

2013-12-20 Thread Andy Bradford
Thus said Richard Hipp on Fri, 20 Dec 2013 19:05:07 -0500:

> http://www.fossil-scm.org/fossil/info/a28c83647d

Is there a  command line option that will find  this artifact? I thought
perhaps the root:trunk symbolic name would  find it, but I was wrong. It
finds c06edd231fc15d145a1c96c39b8fecdb79b33523 which is apparently where
the current trunk began from a branch.

Of course  the following  works, but I  have to guess  at the  number of
artifacts:

fossil timeline -n 10 | tail

Thanks,

Andy
-- 
TAI64 timestamp: 400052b51f20


___
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] Parent of the very first checkin?

2013-12-20 Thread Richard Hipp
On Fri, Dec 20, 2013 at 7:27 PM, David Given  wrote:

> On 21/12/13 00:05, Richard Hipp wrote:
> > Every repository as an initial check-in which is empty.  But it always
> has
> > a different SHA1 hash, since it also includes the timestamp from when the
> > repository was created.
>
> Is it guaranteed that this will only ever be only checkin with no
> parents?


No such guarantee.  Though you will have to do some unsavory things to your
repository to get it into a state where this is not true.



> And that all other checkins will have this as an ultimate
> ancestor? If so, thanks, it's just what I'm looking for.
>
> (It'd be nice if it were tagged so it could be found via a symbolic name
> --- although I suspect that I'm the only person who's asked for this...)
>
> --
> ┌─── dg@cowlark.com ─ http://www.cowlark.com ─
> │ "There does not now, nor will there ever, exist a programming
> │ language in which it is the least bit hard to write bad programs." ---
> │ Flon's Axiom
>
>
> ___
> 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] Parent of the very first checkin?

2013-12-20 Thread David Given
On 21/12/13 00:05, Richard Hipp wrote:
> Every repository as an initial check-in which is empty.  But it always has
> a different SHA1 hash, since it also includes the timestamp from when the
> repository was created.

Is it guaranteed that this will only ever be only checkin with no
parents? And that all other checkins will have this as an ultimate
ancestor? If so, thanks, it's just what I'm looking for.

(It'd be nice if it were tagged so it could be found via a symbolic name
--- although I suspect that I'm the only person who's asked for this...)

-- 
┌─── dg@cowlark.com ─ http://www.cowlark.com ─
│ "There does not now, nor will there ever, exist a programming
│ language in which it is the least bit hard to write bad programs." ---
│ Flon's Axiom



signature.asc
Description: OpenPGP digital signature
___
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] Parent of the very first checkin?

2013-12-20 Thread Richard Hipp
Every repository as an initial check-in which is empty.  But it always has
a different SHA1 hash, since it also includes the timestamp from when the
repository was created.  Example:

http://www.fossil-scm.org/fossil/info/a28c83647d

And the actual text of the manifest artifact:

   http://www.fossil-scm.org/fossil/artifact/a28c83647dfa805f




On Fri, Dec 20, 2013 at 6:23 PM, David Given  wrote:

> hg has a concept of the changeset with uuid
> . This is the empty changeset,
> and is equivalent to the parent of the very first checkin. Checking out
> this changeset will give you an empty repository; checking in with this
> as the parent will give you a new tree, not connected to the old one.
>
> I find myself needing to do this in Fossil: both as something I can
> check out to remove all files from the working directory, and something
> I can use as a parent so I can create multiple revision trees.
>
> AFAIK there's nothing in the Fossil architecture to forbid it --- is
> there any way I can do this?
>
> --
> ┌─── dg@cowlark.com ─ http://www.cowlark.com ─
> │ "There does not now, nor will there ever, exist a programming
> │ language in which it is the least bit hard to write bad programs." ---
> │ Flon's Axiom
>
>
> ___
> 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


[fossil-users] Parent of the very first checkin?

2013-12-20 Thread David Given
hg has a concept of the changeset with uuid
. This is the empty changeset,
and is equivalent to the parent of the very first checkin. Checking out
this changeset will give you an empty repository; checking in with this
as the parent will give you a new tree, not connected to the old one.

I find myself needing to do this in Fossil: both as something I can
check out to remove all files from the working directory, and something
I can use as a parent so I can create multiple revision trees.

AFAIK there's nothing in the Fossil architecture to forbid it --- is
there any way I can do this?

-- 
┌─── dg@cowlark.com ─ http://www.cowlark.com ─
│ "There does not now, nor will there ever, exist a programming
│ language in which it is the least bit hard to write bad programs." ---
│ Flon's Axiom



signature.asc
Description: OpenPGP digital signature
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users