Module

GitHub.Actions.Core

Package
purescript-github-actions-toolkit
Repository
purescript-contrib/purescript-github-actions-toolkit

Exports functions from the @actions/core module provided by GitHub https://github.com/actions/toolkit/tree/main/packages/core

#InputOptions Source

type InputOptions = { required :: Boolean }

Interface for getInput options required: Whether the input is required. If required and not present, will throw required default: false

#exportVariable Source

exportVariable :: { key :: String, value :: String } -> Effect Unit

Sets env variable for this action and future actions in the job name: the name of the variable to set val: the value of the variable

#setSecret Source

setSecret :: String -> Effect Unit

Registers a secret which will get masked from logs

#addPath Source

addPath :: String -> Effect Unit

Prepends input path to the PATH (for this action and future actions)

#getInput Source

getInput :: GetInputArgs -> ExceptT Error Effect String

Gets the value of an input. The value is also trimmed. name: the name of the input to get options: See InputOptions

#getInput' Source

getInput' :: String -> ExceptT Error Effect String

Gets the value of an input. The value is also trimmed. Uses default for options

#setOutput Source

setOutput :: { name :: String, value :: String } -> Effect Unit

Sets the value of an output.

#setCommandEcho Source

setCommandEcho :: Boolean -> Effect Unit

Enables or disables the echoing of commands into stdout for the rest of the step.

#setFailed Source

setFailed :: String -> Effect Unit

Sets the action status to failed. When the action exits it will be with an exit code of 1

#isDebug Source

isDebug :: Effect Boolean

Gets whether Actions Step Debug is on or not

#debug Source

debug :: String -> Effect Unit

Writes debug message to user log

#error Source

error :: String -> Effect Unit

Adds an error issue

#warning Source

warning :: String -> Effect Unit

Adds a warning issue

#info Source

info :: String -> Effect Unit

Writes info to log with console.log.

#startGroup Source

startGroup :: String -> Effect Unit

Begin an output group. Output until the next groupEnd will be foldable in this group

#endGroup Source

endGroup :: Effect Unit

End an output group.

#saveState Source

saveState :: { name :: String, value :: String } -> Effect Unit

Saves state for current action. The state can only be retrieved by this action's post job execution.

#getState Source

getState :: String -> Effect String

Gets the value of an state set by this action's main execution.

#group Source

group :: forall a. { fn :: Aff a, name :: String } -> Aff a

Wrap an asynchronous function call in a group.