commit a43bde7ce71e6f175dcaf79f9e5cfa41a4ad7e61 Author: hsc Date: Sun Mar 30 17:36:08 2025 +0800 ci: 添加 Drone CI 配置和简单 Go 程序- 新增 .drone.yml 文件,配置 Docker 类型的 CI管道 - 添加 hello.go 文件,实现简单的 Go 语言 Hello World 程序 -配置 CI 环境中使用 Golang 1.20 镜像进行构建和测试 diff --git a/.drone.yml b/.drone.yml new file mode 100644 index 0000000..a72dcf8 --- /dev/null +++ b/.drone.yml @@ -0,0 +1,10 @@ +kind: pipeline +type: docker +name: default + +steps: + - name: build + image: golang:1.20 + commands: + - go build + - go test \ No newline at end of file diff --git a/hello.go b/hello.go new file mode 100644 index 0000000..8ac7076 --- /dev/null +++ b/hello.go @@ -0,0 +1,3 @@ +func main() { + fmt.Println("Hello, World!") +} \ No newline at end of file