/
printReleaseNotesTemplate.js
58 lines (37 loc) · 1.7 KB
/
printReleaseNotesTemplate.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
const CHANGELOG_COMMAND =
"git log --pretty=format:'%aN | %s | %h' --abbrev-commit --reverse $(git describe --abbrev=0)..origin/2.x-next"
const execa = require('execa')
const TEMPLATE = `
**⚠️ THIS IS A MAINTENANCE RELEASE OF A PREVIOUS MAJOR VERSION OF SANITY**
We recommend updating to Sanity Studio v3 which provides exceptional flexibility and an unparalleled developer experience. The core packages for Sanity Studio v2 will only receive critical bug fixes until Dec 7th, 2023
Please head over to the documentation for [Sanity Studio v3](https://www.sanity.io/docs/sanity-studio) to learn more.
You can find [migration guides from Studio v2 here](https://www.sanity.io/docs/migrating-from-v2).
## Installation and upgrading
Upgrade the **v2 version** of the Command Line Interface (CLI) with:
npm install --global @sanity/cli@v2
Upgrade Sanity Studio with:
sanity upgrade
# ✨ Highlights
## Awesome feature X
A few words about the awesome feature X, preferably with screengifs
## Awesome feature Y
A few words about the awesome feature Y, preferably with screengifs
## Other features
- This is feature is not that important, but worth mentioning anyway
# 🐛 Notable bugfixes
- Fixes 🐞
- Fixes 🐛
- Fixes 🦗
# 📓 Full changelog
Author | Message | Commit
------------ | ------------- | -------------
${execa.commandSync(CHANGELOG_COMMAND, {shell: true}).stdout}
`
// eslint-disable-next-line no-console
console.log(`
-------- SANITY RELEASE NOTES TEMPLATE --------
Use the following template as a starting point for next release:
A draft can be created here: https://github.com/sanity-io/sanity/releases/new
-------- BEGIN TEMPLATE --------
${TEMPLATE}
-------- END TEMPLATE --------`)