On Aug 24, 2009, at 1:40 PM, Jeff Doar wrote:
> I'd like to retrieve the same sort of information that Fossil makes
> available via its built-in webserver. I can get a list of revisions
> easily enough using "Fossil timeline" but I don't know how to get
> information about each revision. For each revision I'd like to be able
> to get a list of affected files, and for each file I'd like to be able
> to get diffs against the previous revision. I can see that each file
> revision is assigned an artifact ID, and I can see that each
> revision of
> the manifest file identifies all the different file versions in the
> revision, but I can't see an easy way to get that manifest content
> without performing a checkout to a given version.
>
> Along similar lines, is there anything like an "export" command in
> Fossil? i.e., I'd like the ability to retrieve a given version of a
> file
> (possibly just dumping it to stdout) without performing a full
> checkout?
> I know that I can get that content via "Fossil deconstruct" but I'd
> prefer not to dump the entire repository.
>
All of the above is easily "doable" in the sense that it is easy
enough to write code in fossil to do it. But there are no easy-to-use
commands to do it right now (mostly) because I write most of the code
and I've never needed to do any of the things you describe. :-)
There are some "test" commands that do approximately what you want.
You can get a listing of "test" commands using:
fossil test-commands
If you want to get the content of an artifact to standard output, use
this:
fossil test-content-get SHA1HASH -
Replace SHA1HASH above with a unique abbreviation of the sha1 hash of
the artifact you want, of course. The "-" argument at the end of the
line is the file into which the artifact content should be written.
"-" means standard output.
The "fossil test-commands" command works to get you a listing of the
test commands. Unfortunately, the "fossil help" command often does
not work especially well for test commands (due to the fact that
nobody has ever entered appropriate help-text for commands that were
intended for testing only.) So you might have to look at the source
code to figure out exactly what each of the test commands do. Note
also that error-checking on test commands is not done to the same
extent as it is on the documented user commands.
D. Richard Hipp
[email protected]
_______________________________________________
fossil-users mailing list
[email protected]
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users