Skip to content

Fix timestamp retrieval for git commits#18

Open
AdrianVollmer wants to merge 1 commit into
rixx:mainfrom
AdrianVollmer:patch-1
Open

Fix timestamp retrieval for git commits#18
AdrianVollmer wants to merge 1 commit into
rixx:mainfrom
AdrianVollmer:patch-1

Conversation

@AdrianVollmer

Copy link
Copy Markdown

Signed commits would trip up the parser:

  File "/home/avollmer/.local/bin/git-backdate", line 89, in get_commit_timestamp
    return dt.datetime.fromtimestamp(int(timestamp))
                                     ~~~^^^^^^^^^^^
ValueError: invalid literal for int() with base 10: 'gpg: Signature made <snip>

The flag introduced with this change removes the signatures and the parser works as expected.

Signed commits would trip up the parser:

```
  File "/home/avollmer/.local/bin/git-backdate", line 89, in get_commit_timestamp
    return dt.datetime.fromtimestamp(int(timestamp))
                                     ~~~^^^^^^^^^^^
ValueError: invalid literal for int() with base 10: 'gpg: Signature made <snip>
```

The flag introduced with this change removes the signatures and the parser works as expected.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant