Vim-go: No flag to disable the template?

Created on 31 Jan 2017  路  2Comments  路  Source: fatih/vim-go

Behavior

I have both vim-template to use some custom Go template, and vim-go.
When opening I get some strange mix of the two.

Example:
vim test.go (new file)

package main                                                                    

import "fmt"

func main() {
    fmt.Println("vim-go")
}
package main;

import (
    "fmt"
)

func main(){
    fmt.Println("Hello World");

Steps to reproduce:

  1. Get vim-template
  2. Open a .go file.
  3. That should be it, to already see some strange results.

If that doesn't work, try edit the =template=.go file under ~/.vim/plugged/vim-template/templates or similar.

Configuration

Latest vim-go as of now. Not sure which version though.
go version go1.7.4 linux/amd64

Most helpful comment

Put following line in your vimrc:

let g:go_template_autocreate = 0

All 2 comments

Put following line in your vimrc:

let g:go_template_autocreate = 0

Aha! Thanks, will do =)

Was this page helpful?
0 / 5 - 0 ratings

Related issues

smontazeran picture smontazeran  路  4Comments

svanharmelen picture svanharmelen  路  3Comments

SirmaXX picture SirmaXX  路  3Comments

surest picture surest  路  3Comments

zhangjing picture zhangjing  路  3Comments