Code Repositories xandikos / 36cdbbb
Fix style error. Jelmer Vernooń≥ 1 year, 11 months ago
1 changed file(s) with 8 addition(s) and 4 deletion(s). Raw diff Collapse all Expand all
4747 IndexEntry,
4848 index_entry_from_stat,
4949 write_index_dict,
50 )
50 )
5151 from dulwich.objects import Blob, Tree
5252 from dulwich.pack import SHA1Writer
5353 import dulwich.repo
566566 st = os.lstat(p)
567567 blob = Blob.from_string(b''.join(data))
568568 self.repo.object_store.add_object(blob)
569 index[name.encode(DEFAULT_ENCODING)] = IndexEntry(*index_entry_from_stat(st, blob.id, 0))
570 self._commit_tree(index, message.encode(DEFAULT_ENCODING), author=author)
569 index[name.encode(DEFAULT_ENCODING)] = IndexEntry(
570 *index_entry_from_stat(st, blob.id, 0))
571 self._commit_tree(
572 index, message.encode(DEFAULT_ENCODING),
573 author=author)
571574 return blob.id
572575
573576 def delete_one(self, name, message=None, author=None, etag=None):
598601 with locked_index(self.repo.index_path()) as index:
599602 os.unlink(p)
600603 del index[name.encode(DEFAULT_ENCODING)]
601 self._commit_tree(index, message.encode(DEFAULT_ENCODING), author=author)
604 self._commit_tree(index, message.encode(DEFAULT_ENCODING),
605 author=author)
602606
603607 def get_ctag(self):
604608 """Return the ctag for this store."""