mirror of
https://github.com/jimeh/build-emacs-for-macos.git
synced 2026-02-19 08:26:39 +00:00
fix(plan): correctly parse --test-release-type flag
The --test-release-type flag was essentially broken and ignored, always creating a prerelease release for test builds. Now it can also produce draft releases.
This commit is contained in:
@@ -89,7 +89,7 @@ func planAction(c *cli2.Context, opts *Options) error {
|
||||
GithubToken: c.String("github-token"),
|
||||
}
|
||||
|
||||
if c.String("test-build-type") == "draft" {
|
||||
if c.String("test-release-type") == "draft" {
|
||||
planOpts.TestBuildType = plan.Draft
|
||||
}
|
||||
|
||||
|
||||
@@ -120,10 +120,12 @@ func Create(ctx context.Context, opts *Options) (*Plan, error) {
|
||||
plan.Build.Name += ".test." + testName
|
||||
plan.Release.Title = "Test Builds"
|
||||
plan.Release.Name = "test-builds"
|
||||
|
||||
plan.Release.Prerelease = true
|
||||
plan.Release.Draft = false
|
||||
if opts.TestBuildType == Draft {
|
||||
plan.Release.Prerelease = false
|
||||
plan.Release.Draft = true
|
||||
} else {
|
||||
plan.Release.Prerelease = true
|
||||
}
|
||||
|
||||
index := strings.LastIndex(diskImage, ".")
|
||||
|
||||
Reference in New Issue
Block a user