Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make startYear setting deterministic #698

Closed

Conversation

armanbilge
Copy link
Member

Instead of defaulting to the current year (this was a bad default, I'm sorry) it now defaults to the current year at the time that version of sbt-typelevel was built.

@mergify mergify bot added the core label Apr 18, 2024
@mzuehlke
Copy link
Collaborator

Do you think even having a default for startYear is a good idea in the first place ?
I think it is mostly (exclusively ?) used for the header generation and wouldn't this result in the header being updated each year when we drop a new sbt-tl release ?

The official meaning is

val startYear = settingKey[Option[Int]]("Year in which the project started.").withRank(BMinusSetting)

https://github.com/sbt/sbt/blob/0c6d7b8f300f1e405e2a2db5d84f72d30a7ec901/main/src/main/scala/sbt/Keys.scala#L342

@armanbilge
Copy link
Member Author

armanbilge commented Apr 19, 2024

Do you think even having a default for startYear is a good idea in the first place ?

That's a good point. I think I gave it a default to make the "getting started" experience as fast and easy as possible. But I guess the proper place to do this is in templates where startYear is set appropriately to a fixed year.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants