lifecycle

package
v0.5.1 Latest Latest
Warning

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

Go to latest
Published: Sep 23, 2026 License: AGPL-3.0 Imports: 6 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package lifecycle moves a document through its statuses and rewrites the file. Nothing here prompts, prints or commits.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AppendRationale

func AppendRationale(source []byte) []byte

AppendRationale adds the rejection rationale section to a document, as rejecting one does. `archdoc new --status=rejected` creates a document that is already rejected, so it needs the same section and the same prompt in it; this is exported so that there is one of each rather than a second copy in the templates.

func Apply

func Apply(d *repo.Document, to repo.Status, now time.Time) ([]byte, error)

Apply moves a document to a new status and returns the rewritten file. The document on disk is not touched; writing it is the caller's business.

func Permitted

func Permitted(from repo.Status, strict bool) []repo.Status

Permitted lists the statuses a document may move to from this one, in the order a chooser should offer them. A terminal status has none: to change what an accepted document says, write a new one that updates or obsoletes it.

Types

This section is empty.

Jump to

Keyboard shortcuts

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