打赏

Go获得项目根目录

package main

import (
    "fmt"
    "os"
)

func main() {
    path, _ := os.Getwd()
    fmt.Println(path)
}

 

posted on 2021-11-04 22:25  头大的冯冯  阅读(254)  评论(0编辑  收藏  举报

导航