basilicom/release-notes-bundle

此软件包已被弃用且不再维护。没有建议的替代软件包。

将git日志消息发送到confluence的功能

v0.1.3 2020-02-28 14:01 UTC

README

安装

检查Resources/config/services.yaml中的示例配置。

使用方法

bin/console release-notes:send-to-confluence <version-tag>
bin/console release-notes:send-to-rocket-chat <version-tag>

首先,此命令将从存储库获取所有标签。然后,它将搜索定义的版本/标签以及刚刚设置的标签。之后,它将获取这两个标签之间的所有提交。

如果您使用存储库中的第一个标签,它将获取从初始提交到第一个标签的所有提交以创建变更日志。

Symfony 4.x 配置

请确保在app/config/bundles.php中启用此软件包,例如:

return [
    \Basilicom\ReleaseNotesBundle\ReleaseNotesBundle::class => ['all' => true],
];

Symfony 3.x 配置

与上述相同,但必须在AppKernel.php中的BundleCollection中添加软件包,例如:

if (class_exists('\\Basilicom\\ReleaseNotesBundle\\ReleaseNotesBundle')) {
    $collection->addBundle(new \Basilicom\ReleaseNotesBundle\ReleaseNotesBundle);
}

示例配置

Confluence 发布者
Basilicom\ReleaseNotesBundle\Command\ConfluenceReleaseNotesPublisherCommand:    
    public: true
    tags: ['console.command']
    arguments:
        $confluenceUser: 'your-username'
        $confluencePassword: 'your-password'
        $confluenceUrl: 'https://your-confluence.com'
        $pageId: '123'
RocketChat 发布者

您可以定义所需的消息参数数量。如果您想提供动态版本标签,可以将它作为命令参数附加,并使用保留的version键来使用它。例如:release-notes:send-to-rocket-chat v0.2.4

Basilicom\ReleaseNotesBundle\Command\RocketChatReleaseNotesPublisherCommand:
        public: true
        tags: ['console.command']
        arguments:
            $rocketChatUser: '%env(ROCKET_CHAT_USER)%'
            $rocketChatPassword: '%env(ROCKET_CHAT_PASSWORD)%'
            $rocketChatBaseUri: 'https://rocketchat.your-domain.net'
            $rocketChatChannel: 'the rocket chat channel you want to post to'
            $message: "
                Value 1 will be inserted here -> {key1}                       \n
                
                Version: {version}                  \n
                Verantwortlich: #basilicom          \n
                Datum: {date}
            "
            $messageParameters:
                key1: 'value1'
                date: 'd.M.Y H:i:s'
                version: ''