@@ -7,18 +7,18 @@ import (
77
88 defaultGenerator "github.com/go-semantic-release/changelog-generator-default/pkg/generator"
99 defaultAnalyzer "github.com/go-semantic-release/commit-analyzer-cz/pkg/analyzer"
10+ defaultCI "github.com/go-semantic-release/condition-default/pkg/condition"
11+ githubCI "github.com/go-semantic-release/condition-github/pkg/condition"
12+ gitlabCI "github.com/go-semantic-release/condition-gitlab/pkg/condition"
13+ npmUpdater "github.com/go-semantic-release/files-updater-npm/pkg/updater"
1014 providerGithub "github.com/go-semantic-release/provider-github/pkg/provider"
1115 providerGitlab "github.com/go-semantic-release/provider-gitlab/pkg/provider"
1216 "github.com/go-semantic-release/semantic-release/v2/pkg/analyzer"
1317 "github.com/go-semantic-release/semantic-release/v2/pkg/condition"
14- "github.com/go-semantic-release/semantic-release/v2/pkg/condition/defaultci"
15- githubCI "github.com/go-semantic-release/semantic-release/v2/pkg/condition/github"
16- gitlabCI "github.com/go-semantic-release/semantic-release/v2/pkg/condition/gitlab"
1718 "github.com/go-semantic-release/semantic-release/v2/pkg/generator"
1819 "github.com/go-semantic-release/semantic-release/v2/pkg/plugin"
1920 "github.com/go-semantic-release/semantic-release/v2/pkg/provider"
2021 "github.com/go-semantic-release/semantic-release/v2/pkg/updater"
21- "github.com/go-semantic-release/semantic-release/v2/pkg/updater/npm"
2222 "github.com/urfave/cli/v2"
2323)
2424
@@ -38,20 +38,41 @@ func GetPluginCommands() []*cli.Command {
3838 HideHelp : true ,
3939 },
4040 {
41- Name : condition .CIConditionPluginName + "_default" ,
42- Action : defaultci .Main ,
41+ Name : condition .CIConditionPluginName + "_default" ,
42+ Action : func (c * cli.Context ) error {
43+ plugin .Serve (& plugin.ServeOpts {
44+ CICondition : func () condition.CICondition {
45+ return & defaultCI.DefaultCI {}
46+ },
47+ })
48+ return nil
49+ },
4350 Hidden : true ,
4451 HideHelp : true ,
4552 },
4653 {
47- Name : condition .CIConditionPluginName + "_github" ,
48- Action : githubCI .Main ,
54+ Name : condition .CIConditionPluginName + "_github" ,
55+ Action : func (c * cli.Context ) error {
56+ plugin .Serve (& plugin.ServeOpts {
57+ CICondition : func () condition.CICondition {
58+ return & githubCI.GitHubActions {}
59+ },
60+ })
61+ return nil
62+ },
4963 Hidden : true ,
5064 HideHelp : true ,
5165 },
5266 {
53- Name : condition .CIConditionPluginName + "_gitlab" ,
54- Action : gitlabCI .Main ,
67+ Name : condition .CIConditionPluginName + "_gitlab" ,
68+ Action : func (c * cli.Context ) error {
69+ plugin .Serve (& plugin.ServeOpts {
70+ CICondition : func () condition.CICondition {
71+ return & gitlabCI.GitLab {}
72+ },
73+ })
74+ return nil
75+ },
5576 Hidden : true ,
5677 HideHelp : true ,
5778 },
@@ -95,8 +116,15 @@ func GetPluginCommands() []*cli.Command {
95116 HideHelp : true ,
96117 },
97118 {
98- Name : updater .FilesUpdaterPluginName + "_npm" ,
99- Action : npm .Main ,
119+ Name : updater .FilesUpdaterPluginName + "_npm" ,
120+ Action : func (c * cli.Context ) error {
121+ plugin .Serve (& plugin.ServeOpts {
122+ FilesUpdater : func () updater.FilesUpdater {
123+ return & npmUpdater.Updater {}
124+ },
125+ })
126+ return nil
127+ },
100128 Hidden : true ,
101129 HideHelp : true ,
102130 },
0 commit comments