sourcegraph/internal/own/conf.go
Erik Seliger a0a18a60e9
gating: Add individual switches for disabling tools features (#63686)
This PR adds better gating for disabling the code monitors, notebooks,
search jobs and own features.

## Test plan

Ran locally and verified the features are gone when the env var is set.
Ran again without those and they worked.

---------

Co-authored-by: Stefan Hengl <stefan@sourcegraph.com>
2024-07-16 15:45:38 +02:00

14 lines
160 B
Go

package own
import (
"os"
"strconv"
)
func IsEnabled() bool {
if v, _ := strconv.ParseBool(os.Getenv("DISABLE_OWN")); v {
return false
}
return true
}