Add CI_MERGE_REQUEST_DESCRIPTION env variable
This MR is an updated port of Community contribution !38636 (closed) as the original MR is behind master by a bit and we'd like to merge this as soon as possible.
What does this MR do?
Merge requests contain their own description which is comparable to a git send-mail
cover letter.
If the merge requests contains only a single commit the merge request description equal commit description per default. If the merge request contains multiple commits the description is user defined and ideally contains a summary of the proposed commits.
For CI purposes the merge request description can contain commands change the CI default behaviour. This is useful to explicitly run special cases.
The merge request description could contain a control command like the following:
CI-config: USE_SPECIAL_CASE_Z=1
The CI script can evaluate those options via the following command:
echo "$CI_MERGE_REQUEST_DESCRIPTION" | grep -e "^CI-config:" \
cut -d ':' -f 2 | tr ' ' '\n' > extra_env
This method allow to run corner cases without modifying nor bloating the git log.