janhoy commented on code in PR #4111:
URL: https://github.com/apache/solr/pull/4111#discussion_r2777583187


##########
gradle/changelog.gradle:
##########
@@ -44,25 +44,45 @@ task writeChangelog {
     def jiraRef = jiraMatcher ? jiraMatcher[0].toUpperCase() : "SOLR-XXXX"
     def jiraUrl = "https://issues.apache.org/jira/browse/${jiraRef}";
     def jiraLinks = jiraMatcher ? "links:\n  - name: ${jiraRef}\n    url: 
${jiraUrl}" : ""
-    def title = gitBranch.replaceFirst(/(?i)SOLR-\d\d\d+\b-?/, 
"").replace("-", " ").capitalize()
-    // Warn user when generating empty title
-    if (title.isEmpty()) {
-      println "WARNING: Title in generated changelog is empty, please edit"
-    }
+    def title = gitBranch.replaceFirst(/(?i)SOLR-\d\d\d+-/, "").replace("-", " 
").capitalize()
     // Strip everything before and including '/', then sanitize special 
characters
     def sanitizedBranchName = gitBranch.replaceAll(/^.*\//, 
"").replaceAll(/[^a-zA-Z0-9._-]/, "-")
     def fileName = "changelog/unreleased/${sanitizedBranchName}.yml"
     def file = new File(fileName)
     file.parentFile.mkdirs()
-    file.text = """# See 
https://github.com/apache/solr/blob/main/dev-docs/changelog.adoc
+    file.text = """# (DELETE ALL COMMENTS UP HERE AFTER FILLING THIS IN
+
+# See https://github.com/apache/solr/blob/main/dev-docs/changelog.adoc
+
+# If the change is minor (typos, small improvements), don't bother adding an 
entry.
+
+# title:
+#  * The audience is end-users and administrators, not committers.
+#  * Be short and focused on the user impact, nevertheless multiple sentences 
is fine!
+#  * For technical/geeky details, prefer the commit message instead of 
changelog
+
+# type:
+#  `added` for new features/improvements, opt-in by the user typically 
documented in the ref guide
+#  `changed` for improvements; not opt-in
+#  `fixed` for improvements that are deemed to have fixed buggy behavior
+#  `deprecated` for marking things deprecated
+#  `removed` for code removed
+#  `dependency_update` for updates to dependencies
+#  `other` for anything else, like large/significant refactorings, build 
changes,
+#    test infrastructure, or documentation.
+#    Most such changes are too small/minor to bother with a changelog entry.
+
+# Reference issues as `SOLR-12345` or GitHub `PR#123`.

Review Comment:
   Does this line belong under «title» instead?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to