From 23d4e0a1ca86b32661bff233dcd6e05014646f1b Mon Sep 17 00:00:00 2001 From: Matthew Holt Date: Sat, 23 May 2020 16:32:48 -0600 Subject: [PATCH] Fix env var name, update readme --- README.md | 11 ++++------- cmd/xcaddy/main.go | 2 +- 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index a713468..ad54f7d 100644 --- a/README.md +++ b/README.md @@ -5,16 +5,13 @@ This command line tool and associated Go package makes it easy to make custom bu It is used heavily by Caddy plugin developers as well as anyone who wishes to make custom `caddy` binaries (with or without plugins). -Supports Caddy 2 and up. - -⚠️ Still in development. +⚠️ Still in development. Supports Caddy 2 only. Stay updated, be aware of changes, and please submit feedback! Thanks! ## Requirements - [Go installed](https://golang.org/doc/install) -- [Go modules](https://github.com/golang/go/wiki/Modules) enabled ## Install @@ -29,8 +26,8 @@ $ go get -u github.com/caddyserver/xcaddy/cmd/xcaddy The `xcaddy` command has two primary uses: -- Compile custom `caddy` binaries -- A replacement for `go run` while developing Caddy plugins +1. Compile custom `caddy` binaries +2. A replacement for `go run` while developing Caddy plugins The `xcaddy` command will use the latest version of Caddy by default. You can customize this for all invocations by setting the `CADDY_VERSION` environment variable. @@ -90,7 +87,7 @@ $ xcaddy run $ xcaddy run --config caddy.json ``` -The race detector can be enabled by setting `CADDY_RACE_DETECTOR=1`. +The race detector can be enabled by setting `XCADDY_RACE_DETECTOR=1`. ## Library usage diff --git a/cmd/xcaddy/main.go b/cmd/xcaddy/main.go index d1fe9f0..4d4af9c 100644 --- a/cmd/xcaddy/main.go +++ b/cmd/xcaddy/main.go @@ -30,7 +30,7 @@ import ( var ( caddyVersion = os.Getenv("CADDY_VERSION") - raceDetector = os.Getenv("CADDY_RACE_DETECTOR") == "1" + raceDetector = os.Getenv("XCADDY_RACE_DETECTOR") == "1" ) func main() {