美文网首页
mac下设置gopath环境变量

mac下设置gopath环境变量

作者: faunjoe | 来源:发表于2018-12-21 14:25 被阅读0次

Bash

编辑~/.bash_profile文件,添加以下代码

vim ~/.bash_profile
图片.png

保存,然后执行

source ~/.bash_profile

Zsh

编辑~/.zshrc文件,添加以下代码

vim ~/.zshrc
图片.png

保存,然后执行

source ~/.zshrc

查看go环境变量

go env

相关文章

  • mac下设置gopath环境变量

    mac下设置gopath环境变量 官方指导 Bash 编辑~/.bash_profile文件,添加以下代码 保存,...

  • 使用 Gogland 编写 go 程序

    重要的环境变量 GOPATHgo 1.8 默认的 PATH , 在 Linux/Mac 系下,默认的 GOPATH...

  • mac下Goland设置GOPATH

    现象 用goland打开别人的go项目,可能碰到下面的问题 goland cannot find package ...

  • go语言基础

    设置 GOPATH 有什么意义? 工作区和 GOPATH 是go程序开发的核心概念。环境变量 GOPATH 的值可...

  • mac下设置gopath环境变量

    Bash 编辑~/.bash_profile文件,添加以下代码 保存,然后执行 Zsh 编辑~/.zshrc文件,...

  • Mac 设置goPath

    1、到https://studygolang.com/dl地址下载对应安装包,下载后双击安装即可。 2、go ve...

  • Golang学习笔记-go mod

    环境变量设置 环境变量GO111MODULE可设置三种值:on,off,auto,off表示使用GOPATH模式,...

  • windows下protobuf for go环境搭建

    先下载最新版的golang安装程序; 设置好GOPATH,把%GOPATH%/bin 添加到环境变量; 打开htt...

  • go入门--设置 GOPATH 有什么意义?

    go入门--设置 GOPATH 有什么意义? 参考答案: ​ 1.环境变量 GOPATH 的值可以是一个目录的...

  • Go 学习笔记

    [内容][111] Hello World Part 1 开发环境 环境变量设置 GOROOT GOPATH PA...

网友评论

      本文标题:mac下设置gopath环境变量

      本文链接:https://www.haomeiwen.com/subject/bebmkqtx.html