diff options
author | Sebastian Thiel <byronimo@gmail.com> | 2016-08-02 05:47:27 +0200 |
---|---|---|
committer | Sebastian Thiel <byronimo@gmail.com> | 2016-08-02 05:47:27 +0200 |
commit | 83ebc659ace06c0e0822183263b2c10fe376a43e (patch) | |
tree | 4ded3dd300a5a6d02ce3c354af09dcf516b86bec /git/refs/log.py | |
parent | a4ad7cee0f8723226446a993d4f1f3b98e42583a (diff) | |
parent | df958981ad63edae6fceb69650c1fb9890c2b14f (diff) | |
download | gitpython-83ebc659ace06c0e0822183263b2c10fe376a43e.tar.gz |
Merge branch 'barry-scott-master'
Diffstat (limited to 'git/refs/log.py')
-rw-r--r-- | git/refs/log.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/git/refs/log.py b/git/refs/log.py index fed13608..3078355d 100644 --- a/git/refs/log.py +++ b/git/refs/log.py @@ -114,7 +114,7 @@ class RefLogEntry(tuple): newhexsha = info[41:81] for hexsha in (oldhexsha, newhexsha): if not cls._re_hexsha_only.match(hexsha): - raise ValueError("Invalid hexsha: %s" % hexsha) + raise ValueError("Invalid hexsha: %r" % (hexsha,)) # END if hexsha re doesn't match # END for each hexsha @@ -274,11 +274,12 @@ class RefLog(list, Serializable): raise ValueError("Shas need to be given in binary format") # END handle sha type assure_directory_exists(filepath, is_file=True) + first_line = message.split('\n')[0] committer = isinstance(config_reader, Actor) and config_reader or Actor.committer(config_reader) entry = RefLogEntry(( bin_to_hex(oldbinsha).decode('ascii'), bin_to_hex(newbinsha).decode('ascii'), - committer, (int(time.time()), time.altzone), message + committer, (int(time.time()), time.altzone), first_line )) lf = LockFile(filepath) |