A Jenkins plugin for inserting the commits changelog into the jenkins build environment.
Jenkins插件, 在构建时通过将提交的更新列表插入 Jenkins 构建环境, 从而实现将提交信息通知给飞书/钉钉机器人.
Online office software like Lark(Feishu)/DingTalk feature notification bots.
Testers want to know what bugs were fixed, what features added, what functions modified or refactored when jenkins building started.
Jenkins build environment supports build task variables like BUILD_NUMBER/BUILD_URL, JOB_NAME/JOB_URL, JENKINS_HOME/JENKINS_URL
But Jenkins do not know commits.
So Inserting commits changelog into build environment is a solution.
Is there any way to generate commits changelog? A Jenkins build plugin ?!
This project is an implementation that a jenkins plugin generates commits changelog and insert it into current build environment.
here commits-changelog-env-inserter.hpi is.
Of course. Here is how:
- install maven first, if you haven't. run
brew install maven
on Terminal, macOS. - In root directory of this project, run
mvn verify
. - in
/target/
, you'll seecommits-changelog-env-inserter.hpi
is generated. - Then in Jenkins,
Manage Jenkins
->System Configuration
->Manage Plugins
->Advanced
Tab ->Upload Plugin
,choose file
and thenUpload
. - Then in Jenkins/build tasks,
Configure
->Build Environment
, you'll seeAdd Commits Changelog Information to the Build Environment
, check it and configure as help described. - If you run into anything about maven configure, Google it!
- If you run into anything about Jenkins permissions, Consult your manager!
Check lark_commits_changelog_bot.py
Copyright (c) 2022 Chen Pan
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.