Commit 0b5b409acca23e9b08c84f5ad531e287601448a2

Authored by Simon Glass
1 parent ce267335c3

patman: Use the full commit hash for 'git checkout'

Even with the initial 8 characeters of the hash we will sometimes get a
collision. Use the full hash.

Signed-off-by: Simon Glass <sjg@chromium.org>

Showing 2 changed files with 2 additions and 3 deletions Side-by-side Diff

tools/buildman/control.py
... ... @@ -70,7 +70,7 @@
70 70 if commits:
71 71 for upto in range(0, len(series.commits), options.step):
72 72 commit = series.commits[upto]
73   - print ' ', col.Color(col.YELLOW, commit.hash, bright=False),
  73 + print ' ', col.Color(col.YELLOW, commit.hash[:8], bright=False),
74 74 print commit.subject
75 75 print
76 76 for arg in why_selected:
tools/patman/patchstream.py
... ... @@ -248,8 +248,7 @@
248 248 # Detect the start of a new commit
249 249 elif commit_match:
250 250 self.CloseCommit()
251   - # TODO: We should store the whole hash, and just display a subset
252   - self.commit = commit.Commit(commit_match.group(1)[:8])
  251 + self.commit = commit.Commit(commit_match.group(1))
253 252  
254 253 # Detect tags in the commit message
255 254 elif tag_match: