Skip to content
This repository was archived by the owner on Sep 24, 2025. It is now read-only.

Commit bc025ed

Browse files
author
Kræn Hansen
committed
Fixing the release notes being restored before uploaded + git config
1 parent 0c90b21 commit bc025ed

File tree

1 file changed

+8
-5
lines changed

1 file changed

+8
-5
lines changed

Jenkinsfile

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,6 @@ def copyReleaseNotes(versionBefore, versionAfter) {
5454
file: 'CHANGELOG.md',
5555
text: "# Release ${versionAfter.substring(1)} (${today})\n\n${releaseNotes}\n\n${changeLog}",
5656
)
57-
// Restore the release notes from the template
58-
sh 'cp docs/RELEASENOTES.template.md RELEASENOTES.md'
5957
}
6058

6159
def testExampleApp(String app) {
@@ -119,6 +117,11 @@ pipeline {
119117
url: 'git@github.com:realm/react-realm-context.git'
120118
]]
121119
])
120+
121+
// Set the email and name used when committing
122+
sh 'git config --global user.email "ci@realm.io"'
123+
sh 'git config --global user.name "Jenkins CI"'
124+
122125
// Setting the TAG_NAME env as this is not happening when skipping default checkout.
123126
script {
124127
env.TAG_NAME = sh(
@@ -303,6 +306,7 @@ pipeline {
303306
script {
304307
copyReleaseNotes(versionBefore, nextVersion)
305308
}
309+
306310
// Create a draft release on GitHub
307311
script {
308312
withCredentials([
@@ -312,9 +316,8 @@ pipeline {
312316
}
313317
}
314318

315-
// Set the email and name used when committing
316-
sh 'git config --global user.email "ci@realm.io"'
317-
sh 'git config --global user.name "Jenkins CI"'
319+
// Restore the release notes from the template
320+
sh 'cp docs/RELEASENOTES.template.md RELEASENOTES.md'
318321

319322
// Stage the updates to the files, commit and tag the commit
320323
sh 'git add package.json package-lock.json CHANGELOG.md RELEASENOTES.md'

0 commit comments

Comments
 (0)