123456789101112131415161718192021222324252627282930313233343536 |
- package main
- import (
- "cicv-data-closedloop/common/util"
- "fmt"
- "log"
- "os"
- "strings"
- )
- func main() {
-
-
- dirPath := "D:\\code\\cicv-data-closedloop\\trigger\\pji\\diagnostics"
-
- files, err := os.ReadDir(dirPath)
- if err != nil {
- log.Fatal(err)
- }
-
- content := ""
- for _, file := range files {
-
- if file.IsDir() {
-
- fileName := strings.Replace(strings.Replace(file.Name(), " ", "", -1), "\n", "", -1)
- fmt.Println()
- content = content + "go build --buildmode=plugin -o ./so/pji/" + fileName + ".so ./trigger/pji/diagnostics/" + fileName + "/main/main.go" + "\n"
- }
- }
- util.WriteFile(content, "D:\\test.sh")
- }
|