scriv icon indicating copy to clipboard operation
scriv copied to clipboard

link version headers like Keep a Changelog

Open brettcannon opened this issue 4 years ago • 3 comments

https://keepachangelog.com/ has a neat thing where the version number gets linked to a diff view between versions.

brettcannon avatar Sep 21 '20 01:09 brettcannon

Huh, I had seen the version number in square brackets, and hadn't put it together that it was Markdown reference-style link. I think I've seen changelogs that used the brackets, but didn't make them links, but I can't find any now...

Yes, this is a cool feature. I think I would make the link more explicit, but it's a good idea.

nedbat avatar Sep 21 '20 11:09 nedbat

Yeah, I totally overlooked it initially as well, thinking it was a style thing. 😄

brettcannon avatar Sep 21 '20 16:09 brettcannon

I also like that format, and I was able to get it using a custom entry_title_template:

{% if version %}[{{ version }}](https://github.com/_user_/_project_/compare/_previous_version_tag_...{{version}}) — {% endif %} {{ date.strftime('%Y-%m-%d') }}
{{"\n"}}
Whats Changed in {{version}}

where user and project are handled in my cookiecutter project setup, and I manually correct the previous version tag for each scriv collect.

DonalChilde avatar May 30 '23 18:05 DonalChilde