go-plus

An Enhanced Go Experience For The Atom Editor
授权协议 View license
开发语言 C/C++
所属分类 应用工具、 文档/文本编辑
软件类型 开源软件
地区 不详
投 递 者 诸葛绍元
操作系统 跨平台
开源组织
适用人群 未知
 软件概览

go-plus

An Improved Go Experience For The Atom Editor

image

Overview

This package includes the following functionality:

  • Display information about your current go installation, by running go version and go env
  • Autocomplete using gocode
  • Format your code with gofmt, goimports, or goreturns;optionally run one of these tools on save of any .go file
  • Run go install . and go test -c -o {tempdir} . to verify your code compilesand to keep gocode suggestions up to date
  • Run a variety of linters (e.g. golint, vet, etc.) against your code using gometalinter, revive or golangci-lint
  • Run tests, display test output, and display test coverage using go test -coverprofile
  • Display documentation for identifiers in source code usinggogetdoc
  • Rename the symbol under your cursor using gorename
  • Go to definition using guru or godef
  • Highlight occurrences of an identifier using guru
  • Find usages of an identifier using guru

You can add debug functionality to Atom by installing the following package:

Builds

How Are The Builds Performed?

The following commands are run for the directory of the current file:

  • go install . (for normal .go files)
  • go test -o {tmpdir} -c . (for _test.go files)

Why Are You Running go install Instead Of go build?

gocode (and a few other tools, like gotype) work on .a files (i.e. the package object archive), and the way to keep these up to date is to run go install periodically. This ensures your autocomplete suggestions are kept up to date.

Platforms

The package has CI for OS X, Windows and Ubuntu.

Installing Missing Tools

If you are missing any required tools, you may be prompted to install them. You can also manually install the required tools in your terminal:

go get -u golang.org/x/tools/cmd/goimports
go get -u golang.org/x/tools/cmd/gorename
go get -u github.com/sqs/goreturns
go get -u github.com/mdempsky/gocode
go get -u github.com/alecthomas/gometalinter
go get -u github.com/mgechev/revive
go get -u github.com/golangci/golangci-lint/cmd/golangci-lint
go get -u github.com/zmb3/gogetdoc
go get -u github.com/zmb3/goaddimport
go get -u github.com/rogpeppe/godef
go get -u golang.org/x/tools/cmd/guru
go get -u github.com/fatih/gomodifytags
go get -u github.com/tpng/gopkgs
go get -u github.com/ramya-rao-a/go-outline

Having Issues?

Please consult the FAQ prior to opening an issue: https://github.com/joefitzgerald/go-plus/wiki/FAQ

If you have an issue with debugging, file an issue with go-debug here.

Maintainers

Contributors

A list of contributors can be found at https://github.com/joefitzgerald/go-plus/graphs/contributors. Thank you so much to everyone has contributed to the package ❤️ . You are awesome!

Contributing

Contributions are greatly appreciated. Please fork this repository, make yourchanges, and open a pull request. See Contributing for detailed instructions.

  •       Atom用了段时间了,用起来还不错。用来开发Go的话,需要安装go-plus这个插件。 没在线安装成功,只好离线安装了,记录一下,说不定别人也需要.       步骤如下:       一。配置node环境         brew update         brew install node           brew reinstall node --with-full-ic

  • 通过vite快速创建了一个vue项目,vite相比于vue-cli创建的项目更简洁,而且创建项目的速度远远快于vue-cli,然后项目启动的速度也非常快,我写的简易的后台管理系统启动前端页面的时候能明显感觉出来差异了,本人制作的这个系统算是很小很小的项目了,可想而知如果是大型项目做调试的时候vite比起vue-cli创建的项目能快很多,效率更高,vue-cli创建项目使用的是webpack作为打包

  • MyBatisPuls概述 MyBatis-Plus(简称 MP)是一个 MyBatis 的增强工具,在 MyBatis 的基础上只做增强不做改变,为简化开发、提高效率而生 国产的开源框架,基于MyBatis 核心功能是简化MyBatis的开发,提高效率 底层采用CGlib动态代理方式 其特性有: 无侵入:只做增强不做改变,引入它不会对现有工程产生影响,如丝般顺滑 损耗小:启动即会自动注入基本 C

  • Mybatis 第一章 框架的概述 1.三层架构 mvc: web开发中,使用MVC架构模式。m:数据,v:视图,c:控制器。 ​ c控制器:接受请求,调用service对象,显示请求的处理结果。当前使用servlet作为控制器。 ​ v视图:现在使用jsp,HTML,css,js。显示请求的处理结果,把m中数据显示出来 ​ m数据:来着数据库MySQL,来自文件,来自网络。 MVC作用: ​ 1

 相关资料
  • Go!

    Go! 是一个 PHP 5.4 库,让 PHP 支持 AOP 面向方面编程方法,无需 PECL 扩展、Runkit、evals 或者 DI 容器支持。可使用 XDebug 轻松调试。 示例代码: // Aspect/MonitorAspect.phpnamespace Aspect;use Go\Aop\Aspect;use Go\Aop\Intercept\FieldAccess;use Go\

  • 命令go vet是一个用于检查Go语言源码中静态错误的简单工具。与大多数Go命令一样,go vet命令可以接受-n标记和-x标记。-n标记用于只打印流程中执行的命令而不真正执行它们。-n标记也用于打印流程中执行的命令,但不会取消这些命令的执行。示例如下: hc@ubt:~$ go vet -n pkgtool /usr/local/go/pkg/tool/linux_386/vet golang/

  • 命令go fix会把指定代码包的所有Go语言源码文件中的旧版本代码修正为新版本的代码。这里所说的版本即Go语言的版本。代码包的所有Go语言源码文件不包括其子代码包(如果有的话)中的文件。修正操作包括把对旧程序调用的代码更换为对新程序调用的代码、把旧的语法更换为新的语法,等等。 这个工具其实非常有用。在编程语言的升级和演进的过程中,难免会对过时的和不够优秀的语法及标准库进行改进。这样的改进对于编程语

  • Pact Go的版本目前支持Pact v2规范,访问网站开始学习。 Go-Kit例子 Pact Go代码库中有一个详细的Go Kit 例子,介绍如何使用Pact去测试Go Kit微服务。 原生Go实现 还有一个Go版本的Pact(兼容pact v1.1),不需要运行一个守护进程。如果你不需要v2+的匹配以及运行守护进程,可以考虑使用或者为Pact Go贡献。

  • Panic表示的意思就是有些意想不到的错误发生了。通常我们用来表示程序正常运行过程中不应该出现的,或者我们没有处理好的错误。 package main import "os" func main() { // 我们使用panic来检查预期不到的错误 panic("a problem") // Panic的通常使用方法就是如果一个函数 // 返回一个我们不知道怎么处理

  • 使用os.Exit可以给定一个状态,然后立刻退出程序运行。 package main import "fmt" import "os" func main() { // 当使用`os.Exit`的时候defer操作不会被运行, // 所以这里的``fmt.Println`将不会被调用 defer fmt.Println("!") // 退出程序并设置退出状态值

  • Defer 用来保证一个函数调用会在程序执行的最后被调用。通常用于资源清理工作。 package main import "fmt" import "os" // 假设我们想创建一个文件,然后写入数据,最后关闭文件 func main() { // 在使用createFile得到一个文件对象之后,我们使用defer // 来调用关闭文件的方法closeFile,这个方法将在main

  • 11.1. go test go test命令是一个按照一定的约定和组织来测试代码的程序。在包目录内,所有以_test.go为后缀名的源文件在执行go build时不会被构建成包的一部分,它们是go test测试的一部分。 在*_test.go文件中,有三种类型的函数:测试函数、基准测试(benchmark)函数、示例函数。一个测试函数是以Test为函数名前缀的函数,用于测试程序的一些逻辑行为是否