darcs

Issue 1142 darcs show description --tag foo ==> "foo (+ 4 patches)"

Title darcs show description --tag foo ==> "foo (+ 4 patches)"
Priority wishlist Status needs-implementation
Milestone Resolved in
Superseder Nosy List darcs-devel, dmitry.kurochkin, jaredj, kowey, thorkilnaur, twb
Assigned To
Topics ProbablyEasy

Created on 2008-10-11.06:35:10 by twb, last changed 2009-08-27.14:33:45 by admin.

Messages
msg6304 (view) Author: twb Date: 2008-10-11.06:35:07
Darcs itself has some code so that building from a darcs checkout
instead of a release tarball results in a version string like
"2.0.3pre1 (+ 66 patches)".  This functionality is useful for other
darcs repositories, too.

In git there is a command called "git-describe" which emits the same
kind of information.  Perhaps we should have a "darcs describe" or
"darcs show description" to make it really easy to get such a string?

"darcs show description --tag x" would find the newest tag matching
"x", and emit that tag and the number of patches in the repository
that aren't part of that tag.  So for the same repo, one might find

  $ darcs show description --tag 2.0.2
  2.0.2 (+ 257 patches)
  $ darcs show description --tag 2.1.0pre3
  2.1.0pre3 (+ 17 patches)

Omitting --tag would imply that any tag matches.

I guess at the moment you can get the simple (no --tag) case with:

  echo "$(darcs show tags | head -1) (+ $(darcs changes --count --from-tag .) patches)"
History
Date User Action Args
2008-10-11 06:35:10twbcreate
2008-10-12 10:38:17thorkilnaursetpriority: wishlist
nosy: kowey, dagit, simon, twb, thorkilnaur, dmitry.kurochkin
2009-04-09 14:04:52koweysetstatus: unread -> needs-reproduction
nosy: kowey, dagit, simon, twb, thorkilnaur, dmitry.kurochkin
2009-08-10 23:48:12adminsetnosy: - dagit
2009-08-25 17:30:59adminsetnosy: + darcs-devel, - simon
2009-08-26 18:09:45koweysetstatus: needs-reproduction -> needs-implementation
nosy: + jaredj
topic: + ProbablyEasy
2009-08-27 14:33:45adminsetnosy: kowey, darcs-devel, twb, thorkilnaur, jaredj, dmitry.kurochkin