Mercurial > hg > fetch
diff README.txt @ 55:2dfdff7549b2
note how example works
author | Jeff Hammel <jhammel@mozilla.com> |
---|---|
date | Tue, 15 Nov 2011 16:40:31 -0800 |
parents | 81fe0523a078 |
children |
line wrap: on
line diff
--- a/README.txt Tue Nov 15 16:20:01 2011 -0800 +++ b/README.txt Tue Nov 15 16:40:31 2011 -0800 @@ -29,6 +29,19 @@ particular ``fetch`` run. +Example +------- + +After you checkout the `repository <http://k0s.org/mozilla/hg/fetch>`_ +and run ``python setup.py develop``, you should be able to run +``fetch`` on the example manifest:: + + fetch example.txt + +This will create a ``tmp`` directory relative to the manifest and pull +down several resources to it. + + Fetchers -------- @@ -82,9 +95,27 @@ on destination subpaths. The CLI option ``--dest`` is intended for this purpose but currently unused. - * fetcher options: + * fetcher options: currently ``read_manifests`` reads an unused + column into ``options`` when present in the form of a string like + ``foo=one,bar=two`` into a dict like + ``{'foo': 'one', 'bar': 'two'}``. This hasn't been needed yet and + is unused. If we want to have resource-specific options, we should + use this and make it work. Otherwise it can be deleted. - * note python 2.5+ specifics: + * python package fetcher: often you will want to fetch a python + package as a resource. This would essentially fetch the object + (using another fetcher) and take the (untarred) result of + ``python setup.py sdist`` as a resource. This will strip out files + that aren't part of the python package. Unknowns include how to + specify the sub-fetcher. You could also include other + domain-specific fetchers as needed. + + * note python 2.5+ specifics: ``fetch`` currently uses at least + ``os.path.relpath`` from python 2.5 and perhaps other 2.5+isms as + well. These should at least be documented and checked for if not + obviated. One such reimplementation is at + https://github.com/mozilla/mozbase/blob/master/manifestdestiny/manifestparser.py#L66 + Unsolved Problems -----------------