mirror of
https://github.com/anomalyco/opencode.git
synced 2026-02-01 22:48:16 +00:00
feat(release): add highlights template to draft releases (#10745)
This commit is contained in:
@@ -4,6 +4,35 @@ import { $ } from "bun"
|
|||||||
import { Script } from "@opencode-ai/script"
|
import { Script } from "@opencode-ai/script"
|
||||||
import { buildNotes, getLatestRelease } from "./changelog"
|
import { buildNotes, getLatestRelease } from "./changelog"
|
||||||
|
|
||||||
|
const highlightsTemplate = `## Highlights
|
||||||
|
|
||||||
|
<!--
|
||||||
|
Add highlights before publishing. Delete this section if no highlights.
|
||||||
|
|
||||||
|
- For multiple highlights, use multiple <highlight> tags
|
||||||
|
- Highlights with the same source attribute get grouped together
|
||||||
|
-->
|
||||||
|
|
||||||
|
<!--
|
||||||
|
<highlight source="SourceName (TUI/Desktop/Web/Core)">
|
||||||
|
<h2>Feature title goes here</h2>
|
||||||
|
<p short="Short description used for Desktop Recap">
|
||||||
|
Full description of the feature or change
|
||||||
|
</p>
|
||||||
|
|
||||||
|
https://github.com/user-attachments/assets/uuid-for-video (you will want to drag & drop the video or picture)
|
||||||
|
|
||||||
|
<img
|
||||||
|
width="1912"
|
||||||
|
height="1164"
|
||||||
|
alt="image"
|
||||||
|
src="https://github.com/user-attachments/assets/uuid-for-image"
|
||||||
|
/>
|
||||||
|
</highlight>
|
||||||
|
-->
|
||||||
|
|
||||||
|
`
|
||||||
|
|
||||||
let notes: string[] = []
|
let notes: string[] = []
|
||||||
|
|
||||||
console.log("=== publishing ===\n")
|
console.log("=== publishing ===\n")
|
||||||
@@ -11,6 +40,7 @@ console.log("=== publishing ===\n")
|
|||||||
if (!Script.preview) {
|
if (!Script.preview) {
|
||||||
const previous = await getLatestRelease()
|
const previous = await getLatestRelease()
|
||||||
notes = await buildNotes(previous, "HEAD")
|
notes = await buildNotes(previous, "HEAD")
|
||||||
|
notes.unshift(highlightsTemplate)
|
||||||
}
|
}
|
||||||
|
|
||||||
const pkgjsons = await Array.fromAsync(
|
const pkgjsons = await Array.fromAsync(
|
||||||
|
|||||||
Reference in New Issue
Block a user