github_script

package
v1.4.2 Latest Latest
Warning

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

Go to latest
Published: Jan 14, 2026 License: MIT Imports: 0 Imported by: 0

Documentation

Overview

Package github_script provides a typed wrapper for actions/github-script.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GithubScript

type GithubScript struct {
	// The script to run. Required.
	Script string `yaml:"script,omitempty"`

	// The GitHub token to use for authentication. Defaults to github.token.
	GithubToken string `yaml:"github-token,omitempty"`

	// Whether to enable debug logging.
	Debug bool `yaml:"debug,omitempty"`

	// An optional user-agent string.
	UserAgent string `yaml:"user-agent,omitempty"`

	// A comma-separated list of API previews to accept.
	Previews string `yaml:"previews,omitempty"`

	// How the result will be encoded. Can be "string" or "json".
	ResultEncoding string `yaml:"result-encoding,omitempty"`

	// The number of times to retry a request.
	Retries int `yaml:"retries,omitempty"`

	// A comma-separated list of status codes that will NOT be retried.
	RetryExemptStatusCodes string `yaml:"retry-exempt-status-codes,omitempty"`
}

GithubScript wraps the actions/github-script@v7 action. Run JavaScript in your workflows using the GitHub API and workflow contexts.

func (GithubScript) Action

func (a GithubScript) Action() string

Action returns the action reference.

func (GithubScript) Inputs

func (a GithubScript) Inputs() map[string]any

Inputs returns the action inputs as a map.

Jump to

Keyboard shortcuts

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