The release note created by 'genenrate-release-notes.sh' is pushed to
the master branch. Make sure the change is submitted to the same branch
in Gerrit.
And remove the sed command to append a new release note file in the
'index.rst' file since the file already includes a wildcard match
'release-notes-*'.
Change-Id: Id396d8fec4eae97b627fa490ea20b2c5f437b998
Signed-off-by: Sangwook Ha <sangwook.ha@verizon.com>
git clone -b "$GERRIT_BRANCH" https://git.opendaylight.org/gerrit/docs.git "$DOCS_DIR"
cd "$DOCS_DIR" || exit 1
cp "$WORKSPACE/release-notes.rst" "docs/release-notes/release-notes-${RELEASE,,}.rst"
-sed -i -e '$a release-notes-'"${RELEASE,,}"'' "docs/release-notes/index.rst"
git add docs/release-notes/
GERRIT_COMMIT_MESSAGE="Update release notes for $RELEASE"
# Don't fail the build if this command fails because it's possible that there
# is no changes since last update.
-git review --yes -t "$GERRIT_TOPIC" || true
+git review --yes -t "$GERRIT_TOPIC" "$GERRIT_BRANCH" || true