diff options
author | Alan Donovan <adonovan@google.com> | 2015-01-15 10:13:01 -0500 |
---|---|---|
committer | Alan Donovan <adonovan@google.com> | 2015-01-23 18:40:31 +0000 |
commit | 84312aa521a751f09abebc5bd240a1719f2d1dcf (patch) | |
tree | 9fb0eb5a804ed392c8d5e3f3622d1536817aedff | |
parent | d56977266019f070ce097c082a929f54de17e473 (diff) | |
download | tools-84312aa521a751f09abebc5bd240a1719f2d1dcf.tar.gz |
refactor/rename: clarify usage message
In the example, we use backslashes (not single quotes) to escape
double-quotes since it works on both Windows and POSIX.
Change-Id: Id883f5457bec4d8a36d5b12c759ad385125a98a6
Reviewed-on: https://go-review.googlesource.com/2862
Reviewed-by: Robert Griesemer <gri@golang.org>
-rw-r--r-- | refactor/rename/rename.go | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/refactor/rename/rename.go b/refactor/rename/rename.go index fde3287..6543685 100644 --- a/refactor/rename/rename.go +++ b/refactor/rename/rename.go @@ -55,13 +55,12 @@ Flags: "encoding/json"::x object x anywhere within a package json.go::x object x within file json.go + Double-quotes must be escaped when writing a shell command. + Quotes may be omitted for single-segment import paths such as "fmt". + For methods, the parens and '*' on the receiver type are both optional. - Double-quotes may be omitted for single-segment import paths - such as fmt. They may need to be escaped when writing a - shell command. - It is an error if one of the ::x queries matches multiple objects. @@ -99,7 +98,7 @@ Examples: Rename the object whose identifier is at byte offset 123 within file file.go. -% gorename -from '"bytes".Buffer.Len' -to Size +% gorename -from \"bytes\".Buffer.Len' -to Size Rename the "Len" method of the *bytes.Buffer type to "Size". |