Use full timestamps (with timezone) for changelog entries
RPM has supported using full timestamps with timezone information since RPM 4.14 (Fedora 28, RHEL/CentOS 8). Let's actually include that information since it provides total fidelity from a Git commit to a changelog entry. Signed-off-by: Neal Gompa <ngompa13@gmail.com>
This commit is contained in:
parent
1758b94c5e
commit
474f64ae41
2 changed files with 3 additions and 3 deletions
|
@ -29,7 +29,7 @@ Note: You can also generate a good basic changelog using::
|
||||||
|
|
||||||
git log --after=2018-01-28 --pretty=oneline \
|
git log --after=2018-01-28 --pretty=oneline \
|
||||||
--format='%w(1000)**%h**%n* %cd %an <%ae>%n%w(60,0,2)- %s%n' \
|
--format='%w(1000)**%h**%n* %cd %an <%ae>%n%w(60,0,2)- %s%n' \
|
||||||
--date="format:%a %b %d %Y"
|
--date="format:%a %b %d %T %Z %Y"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -99,9 +99,9 @@ def main(args):
|
||||||
message = wrapper.fill(commit.message.split('\n')[0].strip('- '))
|
message = wrapper.fill(commit.message.split('\n')[0].strip('- '))
|
||||||
|
|
||||||
if last_commit:
|
if last_commit:
|
||||||
print(f"* {commit_dt.strftime('%a %b %d %Y')} {commit.author.name} <{commit.author.email}> - {nvr[1]}-{nvr[2]}")
|
print(f"* {commit_dt.strftime('%a %b %d %T %Z %Y')} {commit.author.name} <{commit.author.email}> - {nvr[1]}-{nvr[2]}")
|
||||||
else:
|
else:
|
||||||
print(f"* {commit_dt.strftime('%a %b %d %Y')} {commit.author.name} <{commit.author.email}>")
|
print(f"* {commit_dt.strftime('%a %b %d %T %Z %Y')} {commit.author.name} <{commit.author.email}>")
|
||||||
print("- %s" % message)
|
print("- %s" % message)
|
||||||
print()
|
print()
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue