erkstrict

package
v0.5.11 Latest Latest
Warning

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

Go to latest
Published: Oct 25, 2022 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package erkstrict controls if erk is running in strict mode.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsStrictMode

func IsStrictMode() bool

IsStrictMode reports if erk is running in strict mode.

On the first run or after UnsetStrictMode is called, it reparses the strict mode. If the ERK_STRICT_MODE environment variable is set, it uses that value ("true" to enable, "false" to disable). Otherwise, it checks if it is running under tests by looking for a -test.* flag, which is automatically added by `go test`.

func SetStrictMode

func SetStrictMode(enabled bool)

SetStrictMode to the provided state.

func UnsetStrictMode

func UnsetStrictMode()

UnsetStrictMode returns strict mode to the pristine state. It will check again for the ERK_STRICT_MODE environment variable and -test.* flag.

Types

This section is empty.

Jump to

Keyboard shortcuts

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