Page MenuHomeSoftware Heritage

No OneTemporary

diff --git a/README.md b/README.md
new file mode 100644
index 0000000..0ff3b7d
--- /dev/null
+++ b/README.md
@@ -0,0 +1,44 @@
+swh-loader-mercurial
+=========================
+
+# Configuration file
+
+In usual location for a loader, *{/etc/softwareheritage/ | ~/.swh/ |
+~/.config/swh/}loader/hg.yml*:
+
+``` YAML
+storage:
+ cls: remote
+ args:
+ url: http://localhost:5002/
+
+send_contents: True
+send_directories: True
+send_revisions: True
+send_releases: True
+send_occurrences: True
+content_packet_size: 1000
+content_packet_size_bytes: 1073741824
+directory_packet_size: 2500
+revision_packet_size: 1000
+release_packet_size: 1000
+occurrence_packet_size: 1000
+```
+
+# Basic use
+
+From python3's toplevel:
+
+``` Python
+project = '756015-ipv6'
+directory = '/home/storage/hg/repo/%s' % project
+origin_url = 'https://%s.googlecode.com' % project
+
+import logging
+logging.basicConfig(level=logging.DEBUG)
+
+from swh.loader.mercurial.tasks import LoadMercurialTsk
+
+t = LoadMercurialTsk()
+t.run(origin_url=origin_url, directory=directory, visit_date='2016-05-03T15:16:32+00:00')
+```

File Metadata

Mime Type
text/x-diff
Expires
Fri, Jul 4, 11:16 AM (3 w, 2 d ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
3214668

Event Timeline