/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to breezy/git/commit.py

  • Committer: Jelmer Vernooij
  • Date: 2020-08-22 22:46:24 UTC
  • mfrom: (7490.40.105 work)
  • mto: This revision was merged to the branch mainline in revision 7521.
  • Revision ID: jelmer@jelmer.uk-20200822224624-om4a4idsr7cn8jew
merge lp:brz/3.1.

Show diffs side-by-side

added added

removed removed

Lines of Context:
19
19
 
20
20
from dulwich.index import (
21
21
    commit_tree,
 
22
    read_submodule_head,
22
23
    )
23
24
import stat
24
25
 
42
43
    Blob,
43
44
    Commit,
44
45
    )
45
 
from dulwich.index import read_submodule_head
46
46
 
47
47
 
48
48
from .mapping import (
75
75
    def record_iter_changes(self, workingtree, basis_revid, iter_changes):
76
76
        seen_root = False
77
77
        for change in iter_changes:
 
78
            if change.kind == (None, None):
 
79
                # Ephemeral
 
80
                continue
78
81
            if change.versioned[0] and not change.copied:
79
82
                file_id = self._mapping.generate_file_id(change.path[0])
80
83
            elif change.versioned[1]:
115
118
                finally:
116
119
                    f.close()
117
120
                sha = blob.id
118
 
                entry.text_size = st.st_size
 
121
                if st is not None:
 
122
                    entry.text_size = st.st_size
 
123
                else:
 
124
                    entry.text_size = len(blob.data)
119
125
                entry.git_sha1 = sha
120
126
                self.store.add_object(blob)
121
127
            elif change.kind[1] == "symlink":