entry

package
v0.15.1 Latest Latest
Warning

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

Go to latest
Published: Oct 9, 2023 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

Package entry provides a datastructure for changelog entries.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Entry

type Entry struct {
	Previous *Entry // Get or Set the previous entry in the changelog.
	Next     *Entry // Get or Set the next entry in the changelog.

	Tag        string
	Date       time.Time
	Added      []string
	Changed    []string
	Deprecated []string
	Removed    []string
	Fixed      []string
	Security   []string
	Other      []string
}

Entry represents a single entry in the changelog

func NewEntry

func NewEntry(tag string, date time.Time) Entry

NewEntry creates a new entry (node) that can be added to the changelog datastructure.

func (*Entry) Append

func (e *Entry) Append(section string, entry string) error

Append updates the given section in the entry..

func (*Entry) GetSection

func (e *Entry) GetSection(section string) []string

GetSection uses reflection to return a given section in the entry. If the section does not exist, an empty slice is returned.

Jump to

Keyboard shortcuts

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