Mercurial > hg
diff hgext/largefiles/basestore.py @ 18999:c1b5f9c4d989
largefiles: refactoring - return hex from _getfile and copyandhash
author | Mads Kiilerich <madski@unity3d.com> |
---|---|
date | Mon, 15 Apr 2013 23:35:18 +0200 |
parents | c2d079387b2c |
children | ad993cb7bbb1 |
line wrap: on
line diff
--- a/hgext/largefiles/basestore.py Mon Apr 15 23:32:33 2013 +0200 +++ b/hgext/largefiles/basestore.py Mon Apr 15 23:35:18 2013 +0200 @@ -8,7 +8,6 @@ '''base class for store implementations and store-related utility code''' -import binascii import re from mercurial import util, node, hg @@ -74,7 +73,7 @@ createmode=self.repo.store.createmode) try: - hhash = binascii.hexlify(self._getfile(tmpfile, filename, hash)) + hhash = self._getfile(tmpfile, filename, hash) except StoreError, err: ui.warn(err.longmessage()) hhash = "" @@ -128,7 +127,7 @@ def _getfile(self, tmpfile, filename, hash): '''Fetch one revision of one file from the store and write it to tmpfile. Compute the hash of the file on-the-fly as it - downloads and return the binary hash. Close tmpfile. Raise + downloads and return the hash. Close tmpfile. Raise StoreError if unable to download the file (e.g. it does not exist in the store).''' raise NotImplementedError('abstract method')