sbt-header icon indicating copy to clipboard operation
sbt-header copied to clipboard

Preserve copyright years

Open retronym opened this issue 10 years ago • 7 comments

Rather than just writing the new header into files, it would be better to "merge" the old and new headers, taking the current year and overall format from the configured header, and the copyright year ranges from the old.

retronym avatar May 04 '15 12:05 retronym

WIP https://github.com/retronym/sbt-header/pull/1

retronym avatar May 04 '15 12:05 retronym

I haven't looked into your code yet, but one feature I want to keep is overwriting existing headers in order to enforce a single header thought the whole project. Of course an option to allow for file specific dates is fine and maybe another one (not the default) to keep (the format of) existing headers. If you plan for the latter, too, please add another issue/PR, i.e. let's keep this focussed on optionally preserving the copyright year(s).

hseeberger avatar May 04 '15 19:05 hseeberger

I'm all for consistent headers too. I think we can expose a new boolean setting that one can use to enable the date range merging.

retronym avatar May 04 '15 23:05 retronym

@retronym did you ever get round to finishing this off? Sounds like something I'd be interested in too.

fommil avatar Jan 12 '16 22:01 fommil

I can finish it.

FelAl avatar May 31 '16 07:05 FelAl

note for people subscribed here that progress was made here by way of #142.

and sbt-header is now used by the akka and akka-http projects:

  • https://github.com/akka/akka-http/pull/1738
  • https://github.com/akka/akka/pull/24715.

dwijnand avatar Mar 16 '18 09:03 dwijnand

Probably related: #282

mkurz avatar Oct 18 '22 11:10 mkurz