vercelconfig

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: May 4, 2026 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const (
	BranchPattern = "entire/**"
	FileName      = "vercel.json"
)

Variables

This section is empty.

Functions

func CachedSettings

func CachedSettings() (*settings.EntireSettings, error)

CachedSettings returns the most recently initialized repository settings.

func DeploymentDisabled

func DeploymentDisabled(config map[string]any) bool

DeploymentDisabled reports whether Entire branches are disabled in the config.

func InitSettings

func InitSettings(ctx context.Context) error

InitSettings loads repository settings for the current command context and stores them in a small package cache.

func Load

func Load(path string) (map[string]any, bool, error)

Load reads a Vercel config file if present.

func Marshal

func Marshal(config map[string]any) ([]byte, error)

Marshal formats a Vercel config with a trailing newline.

func MaybeMergeMetadataBranchConfig

func MaybeMergeMetadataBranchConfig(repo *git.Repository, rootTreeHash plumbing.Hash) (plumbing.Hash, error)

MaybeMergeMetadataBranchConfig ensures the metadata branch root tree contains a vercel.json disabling deployments for Entire branches when Vercel support is enabled in cached settings. Existing vercel.json content is preserved.

func MergeDeploymentDisabled

func MergeDeploymentDisabled(config map[string]any)

MergeDeploymentDisabled sets deploymentEnabled["entire/**"] = false while preserving other fields.

func ResetSettingsCache

func ResetSettingsCache()

ResetSettingsCache clears the cached settings. Primarily intended for tests that exercise multiple repositories in one process.

Types

This section is empty.

Jump to

Keyboard shortcuts

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