Documentation
¶
Index ¶
- Constants
- func CachedSettings() (*settings.EntireSettings, error)
- func DeploymentDisabled(config map[string]any) bool
- func InitSettings(ctx context.Context) error
- func Load(path string) (map[string]any, bool, error)
- func Marshal(config map[string]any) ([]byte, error)
- func MaybeMergeMetadataBranchConfig(repo *git.Repository, rootTreeHash plumbing.Hash) (plumbing.Hash, error)
- func MergeDeploymentDisabled(config map[string]any)
- func ResetSettingsCache()
Constants ¶
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 ¶
DeploymentDisabled reports whether Entire branches are disabled in the config.
func InitSettings ¶
InitSettings loads repository settings for the current command context and stores them in a small package cache.
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 ¶
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.