Okay, so probably my terminology exposes how I am not nearly fluent in darcs, but am translating it to svn in my head. Darcs has tags, patches, and changesets, but not versions, and it has get instead of checkout.
So far, I've been doing Weblocks development on my Macbook, but I wanted to be able to show what we've been working on to other people, so I decided to set it up on the Slicehost slice I've been paying for and not using for months now. Mostly, installing everything on Ubuntu was much easier than it had been on OS X, party because I'd done it before, but more because I didn't have to recompile SBCL. I was basically able to apt-get install everything I needed: sbcl, postgresql, cvs, svn, git, mercurial, darcs, and possibly some things I'm forgetting. I got clbuild from darcs and did ./clbuild install weblocks prevalence, just as I had done in the past. I updated my clsql to the clsql-fluid branch, and installed bordeaux-threads. I got an error saying I needed usocket, and I installed that. Then, I got this error:
; SB-INT:SIMPLE-READER-PACKAGE-ERROR at 437 (line 14, column 28)
on #<SB-SYS:FD-STREAM for "file /home/smee/clbuild/source/weblocks/src/
debug-mode.lisp" {100437C231}>:
; package "HUNCHENTOOT-MP" not found
; compilation aborted after 0:00:00
WARNING:
COMPILE-FILE warned while performing #<COMPILE-OP NIL {1002CF3021}>
on
#<CL-SOURCE-FILE "debug-mode" {10029E26C1}>.
debugger invoked on a ASDF:COMPILE-FAILED in thread #<THREAD "initial
thread" RUNNING {100266B2E1}>:
erred while invoking #<COMPILE-OP NIL {1002CF3021}> on
#<CL-SOURCE-FILE "debug-mode" {10029E26C1}>
basically and didn't know what to do, so I asked the ever-helpful Weblocks google group, and was informed that the current stable version of Weblocks didn't yet work with the latest version of Hunchentoot, which had been just updated, but that it should work if I downgraded my Hunchentoot installation. This is where, as usual, I ran into some problems.
It took me a while to actually figure out how to get an old version from a darcs repository. Here's an example of one of the less helpful bits of darcs documentation I encountered:
How do I go back to an older version of my repository?
Short answer: darcs get --to-match
Long answer: What exactly do you mean by go back to an older version?
http://wiki.darcs.net/DarcsWiki/FrequentlyAskedQuestions#head-e393e169c2c1ab8e991ff19fd0d09d29ce6c23f3
I went here and saw this:
To reproduce the state of a repository `R' as at tag `t', use the command `darcs get -tag t R'. The command `darcs show tags' lists all tags in the current repository.
but got confused when running "darcs show tags" revealed that there were no tags in this repository. The same page also said:
If you want to get a specific version of a repository, you have a few options. You can either use the --tag, --to-patch or --to-match options, or you can use the --context=FILENAME option, which specifies a file containing a context generated with darcs changes --context.
which seemed like it was getting me closer, but which I still got wrong, because I was stuck on the idea of tags. This page was the one that finally made sense to me:
Here's what did end up working:
- darcs changes, to see the patch names so as to use them later. In this case, I saw that it had gone from "version 0.15.7" (the one I wanted) to "version 1.0.0".
- darcs unrecord -p 1.0, to remove the most recent patch and go back to the version before that.
- darcs revert, for the change made in 2. to actually take effect, with 'a' to revert all changes at once without saying 'y' for each one.
And that did it! Weblocks is now working on my slice! As usual with me, the way darcs works seems pretty clear from the documentation after the fact.
Filed under:
clbuild,
cvs,
darcs,
git,
how-to,
Lisp,
Mercurial,
OS X,
PostgreSQL,
svn,
Ubuntu,
Weblocks