From 579d3de996a6f99a58e49798a0e75cd677021067 Mon Sep 17 00:00:00 2001 From: hzfui Date: Thu, 25 Apr 2024 09:40:17 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 6 +++--- util.go | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 3ac696f..6cbe0c6 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # go-crossplane An unofficial Go port of the NGINX config/JSON converter [crossplane](https://github.com/nginxinc/crossplane). - +#### 修复build后输入到文件为字符串的问题 ## Parse This is an example that takes a path to an NGINX config file, converts it to JSON, and prints the result to stdout. ```go @@ -11,7 +11,7 @@ import ( "fmt" "os" - "github.com/aluttik/go-crossplane" + "github.com/HEFUHUI/go-crossplane" ) func main() { @@ -43,7 +43,7 @@ import ( "io/ioutil" "os" - "github.com/aluttik/go-crossplane" + "github.com/HEFUHUI/go-crossplanee" ) func main() { diff --git a/util.go b/util.go index 5ab33e5..4ca7348 100644 --- a/util.go +++ b/util.go @@ -25,7 +25,7 @@ func isSpace(s string) bool { } func repr(s string) string { - q := fmt.Sprintf("%q", s) + q := fmt.Sprintf("%s", s) for _, char := range s { if char == '"' { q = strings.ReplaceAll(q, `\"`, `"`)