Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(6)

Issue 4382053: code review 4382053: misc/vim: add plugin with Fmt command. (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
14 years, 6 months ago by dchest
Modified:
14 years, 6 months ago
Reviewers:
CC:
golang-dev, dsymonds, niemeyer
Visibility:
Public.

Description

misc/vim: add plugin with Fmt command. Fmt command filters the current Go buffer through gofmt. It tries to preserve cursor position and avoids replacing the buffer with stderr output.

Patch Set 1 #

Patch Set 2 : diff -r 8e011ae43486 https://go.googlecode.com/hg/ #

Patch Set 3 : diff -r 8e011ae43486 https://go.googlecode.com/hg/ #

Patch Set 4 : diff -r 8e011ae43486 https://go.googlecode.com/hg/ #

Total comments: 4

Patch Set 5 : diff -r 44dd4f4c2703 https://go.googlecode.com/hg/ #

Unified diffs Side-by-side diffs Delta from patch set Stats (+30 lines, -0 lines) Patch
A misc/vim/ftplugin/go/fmt.vim View 1 2 3 4 1 chunk +30 lines, -0 lines 0 comments Download

Messages

Total messages: 11
dchest
Hello golang-dev@googlegroups.com (cc: golang-dev@googlegroups.com), I'd like you to review this change to https://go.googlecode.com/hg/
14 years, 6 months ago (2011-04-12 12:03:24 UTC) #1
dchest
Hello golang-dev@googlegroups.com (cc: golang-dev@googlegroups.com), Please take another look.
14 years, 6 months ago (2011-04-12 12:32:33 UTC) #2
dsymonds
I'm personally happy just running !gofmt -w % which does almost exactly the same as ...
14 years, 6 months ago (2011-04-12 14:04:24 UTC) #3
niemeyer
> !gofmt -w % > > which does almost exactly the same as this. Is ...
14 years, 6 months ago (2011-04-12 15:11:58 UTC) #4
dchest
On 2011/04/12 14:04:24, dsymonds wrote: > I'm personally happy just running > !gofmt -w % ...
14 years, 6 months ago (2011-04-12 15:13:36 UTC) #5
niemeyer
http://codereview.appspot.com/4382053/diff/9001/misc/vim/ftplugin/go/fmt.vim File misc/vim/ftplugin/go/fmt.vim (right): http://codereview.appspot.com/4382053/diff/9001/misc/vim/ftplugin/go/fmt.vim#newcode25 misc/vim/ftplugin/go/fmt.vim:25: call cursor(pos, 1) There are better ways to save/restore ...
14 years, 6 months ago (2011-04-12 15:13:49 UTC) #6
dchest
Hello golang-dev@googlegroups.com, dsymonds, niemeyer (cc: golang-dev@googlegroups.com), Please take another look.
14 years, 6 months ago (2011-04-12 16:18:47 UTC) #7
dchest
http://codereview.appspot.com/4382053/diff/9001/misc/vim/ftplugin/go/fmt.vim File misc/vim/ftplugin/go/fmt.vim (right): http://codereview.appspot.com/4382053/diff/9001/misc/vim/ftplugin/go/fmt.vim#newcode25 misc/vim/ftplugin/go/fmt.vim:25: call cursor(pos, 1) On 2011/04/12 15:13:49, niemeyer wrote: > ...
14 years, 6 months ago (2011-04-12 16:19:03 UTC) #8
dsymonds
LGTM I'll let niemeyer take another quick look before submitting.
14 years, 6 months ago (2011-04-13 00:59:51 UTC) #9
niemeyer
LGTM, and works well too. Thanks!
14 years, 6 months ago (2011-04-13 01:52:03 UTC) #10
dsymonds
14 years, 6 months ago (2011-04-13 01:55:50 UTC) #11
*** Submitted as http://code.google.com/p/go/source/detail?r=79173f40bb9d ***

misc/vim: add plugin with Fmt command.

Fmt command filters the current Go buffer through gofmt.
It tries to preserve cursor position and avoids replacing
the buffer with stderr output.

R=golang-dev, dsymonds, niemeyer
CC=golang-dev
http://codereview.appspot.com/4382053

Committer: David Symonds <dsymonds@golang.org>
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b