status

package
v0.0.0-...-832881f Latest Latest
Warning

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

Go to latest
Published: Jul 25, 2025 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewOnBranch

func NewOnBranch(appIO io.IO, conf *configuration.Configuration, repo git.Repo) hooks.Condition

Types

type OnBranch

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

OnBranch prevents an action from being executed you are not working on a specified branch.

Example configuration:

{
  "run": "echo ARRRRRRR",
  "conditions": [
    {
      "run": "CaptainHook::Status.OnBranch",
      "options": {
        "name": "main"
      }
    }
  ]
}

func (*OnBranch) IsApplicableFor

func (c *OnBranch) IsApplicableFor(hook string) bool

func (*OnBranch) IsTrue

func (c *OnBranch) IsTrue(condition *configuration.Condition) bool

Jump to

Keyboard shortcuts

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