basic conf for loader

This commit is contained in:
Andreas Schröpfer
2021-02-27 20:09:29 +01:00
parent ac9b441283
commit cc6e58acd9
7 changed files with 375 additions and 0 deletions

View File

@@ -2,7 +2,9 @@ package main
import (
"fmt"
"os"
"git.ecogood.org/andreas.schroepfer/excelConverter/pkg/loader"
excelize "github.com/360EntSecGroup-Skylar/excelize/v2"
)
@@ -12,4 +14,15 @@ func main() {
sheets := xFile.GetSheetMap()
rows, _ := xFile.GetRows(sheets[4])
fmt.Printf("%#v", rows)
c := loader.Conf{}
c.Values = append(c.Values, loader.Value{})
c.Areas = append(c.Areas, loader.Area{
Cols: []loader.AreaCol{
loader.AreaCol{},
},
})
fd, err := os.OpenFile("conf.json", os.O_CREATE, 0777)
fmt.Println(err)
defer fd.Close()
c.EncodeJSON(fd)
}