当前位置:网站首页>GoLand writes Go program
GoLand writes Go program
2022-07-27 06:46:00 【lianyz1985】
GoLand To write go Program
New->Project->Go, Specify any path , establish go project iris-demo;
File->New->Go File, Input server.go, establish go file ;
Copy the following code to server.go
package main
import (
"github.com/kataras/iris/v12"
)
func main() {
app := iris.New()
app.Logger().SetLevel("debug")
app.Run(iris.Addr(":8080"))
}
Enter the command at the terminal , initialization mode
go mod init iris-demo
Enter the following command at the terminal , Download dependency package
go get -u
If the imported package displays red , And in External Libraries Of Go Modules Display blank , lookup .idea In the catalog workspace.xml file , Add the following code
<component name="VgoProject">
<integration-enabled>true</integration-enabled>
<environment>
<map>
<entry key="GOPROXY" value="https://mirrors.aliyun.com/goproxy/" />
</map>
</environment>
</component>
Problem solving .
边栏推荐
猜你喜欢
随机推荐
FTX 基金会资助1500万帮助新冠疫苗临床实验,将影响全球公共卫生
GoLand 编写go程序
Geonode GeoServer win10 installation tutorial (personal test)
ArcGIS for JS API (2) get the ID set of element services
Socket programming II: using Select
KVM command set management virtual machine
What is special about the rehabilitation orthopedic branch of 3D printing brand?
Shell -- custom variables and assignments
项目实训经历1
2022年全球6家最具技术实力的的智能合约审计公司盘点
Function call of shell script
Shell -- conditional statements (if statements, case statements)
Brief introduction of chip, memory and its key indicators I
Joint query of database
Use -wall to clear code hidden dangers
Decorator functions and the use of class decorators
Shell脚本删除自动清理超过大小的文件
1. CentOS 7 安装 redis
关于在Gazebo中给无人机添加相机(摄像头)之后,无人机无法起飞
Source code compilation and installation lamp and discuz Forum









