Skip to main content
Version: Next

@backstage/plugin-scaffolder-node

Home > @backstage/plugin-scaffolder-node

The scaffolder-node module for @backstage/plugin-scaffolder-backend.

Functions

Function

Description

addFiles(options)

cloneRepo(options)

commitAndPushBranch(options)

commitAndPushRepo(input)

createBranch(options)

createTemplateAction(action)

This function is used to create new template actions to get type safety. Will convert zod schemas to json schemas for use throughout the system.

deserializeDirectoryContents(targetPath, files)

Deserializes a list of serialized files into the target directory.

This method uses resolveSafeChildPath to make sure that files are not written outside of the target directory.

executeShellCommand(options)

Run a command in a sub-process, normally a shell command.

fetchContents(options)

A helper function that reads the contents of a directory from the given URL. Can be used in your own actions, and also used behind fetch:template and fetch:plain

fetchFile(options)

A helper function that reads the content of a single file from the given URL. Can be used in your own actions, and also used behind fetch:plain:file

getRepoSourceDirectory(workspacePath, sourcePath)

initRepoAndPush(input)

parseRepoUrl(repoUrl, integrations)

serializeDirectoryContents(sourcePath, options)

Interfaces

Interface

Description

SerializedFile

TaskBroker

TaskBroker

TaskContext

Task

Type Aliases

Type Alias

Description

ActionContext

ActionContext is passed into scaffolder actions.

ExecuteShellCommandOptions

Options for executeShellCommand().

SerializedTask

SerializedTask

SerializedTaskEvent

SerializedTaskEvent

TaskBrokerDispatchOptions

The options passed to TaskBroker.dispatch() Currently a spec and optional secrets

TaskBrokerDispatchResult

The result of TaskBroker.dispatch()

TaskCompletionState

The state of a completed task.

TaskEventType

TaskEventType

TaskSecrets

TaskSecrets

TaskStatus

The status of each step of the Task

TemplateAction

TemplateActionOptions

TemplateExample

TemplateFilter

TemplateGlobal