aboutsummaryrefslogtreecommitdiffhomepage
path: root/caddyconfig/configadapters.go
diff options
context:
space:
mode:
authorMatt Holt <[email protected]>2021-01-04 11:11:36 -0700
committerGitHub <[email protected]>2021-01-04 11:11:36 -0700
commitc8557dc00bd93ce8ecf0bb724856a320e129c71b (patch)
tree0310586287637c9114228452c6620aa5a84c736a /caddyconfig/configadapters.go
parent1b453dd4fbea2f3a54362fb4c2115bab85cad1b7 (diff)
downloadcaddy-c8557dc00bd93ce8ecf0bb724856a320e129c71b.tar.gz
caddy-c8557dc00bd93ce8ecf0bb724856a320e129c71b.zip
caddyfile: Introduce basic linting and fmt check (#3923)
* caddyfile: Introduce basic linting and fmt check This will help encourage people to keep their Caddyfiles tidy. * Remove unrelated tests I am not sure that testing the output of warnings here is quite the right idea; these tests are just for syntax and parsing success.
Diffstat (limited to 'caddyconfig/configadapters.go')
-rw-r--r--caddyconfig/configadapters.go6
1 files changed, 0 insertions, 6 deletions
diff --git a/caddyconfig/configadapters.go b/caddyconfig/configadapters.go
index 1918fa757..1665fa03d 100644
--- a/caddyconfig/configadapters.go
+++ b/caddyconfig/configadapters.go
@@ -93,12 +93,6 @@ func JSONModuleObject(val interface{}, fieldName, fieldVal string, warnings *[]W
return result
}
-// JSONIndent is used to JSON-marshal the final resulting Caddy
-// configuration in a consistent, human-readable way.
-func JSONIndent(val interface{}) ([]byte, error) {
- return json.MarshalIndent(val, "", "\t")
-}
-
// RegisterAdapter registers a config adapter with the given name.
// This should usually be done at init-time. It panics if the
// adapter cannot be registered successfully.