server

package
v0.5.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 18, 2023 License: GPL-3.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CreatePRContext added in v0.5.0

type CreatePRContext struct {
	Config  *config.Config
	Package config.Package

	Version      string
	JiraIssue    string
	DryRun       bool
	IsPost       bool
	PullRequests []github.PullRequest
	Error        error
}

CreatePRContext is the html/template context used when templating the "create PR" page.

type CreatePRRequest added in v0.5.0

type CreatePRRequest struct {
	Version   string `form:"version"`
	JiraIssue string `form:"jiraIssue"`
	PRCreate  bool   `form:"prCreate"`
}

CreatePRRequest is the query or form data pushed by the web.

type HTTPServer

type HTTPServer struct {
	// contains filtered or unexported fields
}

func New

func New(cfg *config.Config, j jira.Client, patcher patch.Patcher, htmlTemplates fs.FS, staticFiles fs.FS) *HTTPServer

func (HTTPServer) Serve

func (s HTTPServer) Serve() error

type Release

type Release struct {
	Provider string `json:"provider"`
	Project  string `json:"project"`
	Version  string `json:"version"`
}

Release object unmarshaled from the newreleases.io webhook. Some fields omitted for simplicity, refer to the documentation at https://newreleases.io/webhooks

func (Release) IssueSummary

func (r Release) IssueSummary() string

Generates a Textual summary for the release, intended to be used as the Jira issue summary

func (Release) JiraIssue

func (r Release) JiraIssue(cfg *config.JiraIssue) jira.Issue

type TemplateContextError

type TemplateContextError struct {
	patch.TemplateContext
	Error string
}

type TemplateContextPullRequests

type TemplateContextPullRequests struct {
	patch.TemplateContext
	PullRequests []github.PullRequest
}

type TemplateContextURL added in v0.5.0

type TemplateContextURL struct {
	patch.TemplateContext
	URL *url.URL
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL