Put all conf in easy to change consts
This commit is contained in:
parent
98643dd6f1
commit
17c80c0c7f
8
main.go
8
main.go
|
@ -13,13 +13,15 @@ import (
|
|||
func main() {
|
||||
|
||||
const listID = 19
|
||||
const basePath = `http://localhost:8080/api/v1`
|
||||
const filepath = `../api/Featurecreep.md`
|
||||
|
||||
now := time.Now()
|
||||
|
||||
client := sdk.NewAPIClient(&sdk.Configuration{
|
||||
BasePath: "http://localhost:8080/api/v1",
|
||||
BasePath: basePath,
|
||||
DefaultHeader: make(map[string]string),
|
||||
UserAgent: "Go client",
|
||||
UserAgent: "Go migration client",
|
||||
})
|
||||
|
||||
token, _, err := client.UserApi.LoginPost(context.Background(), sdk.ModelsUserLogin{
|
||||
|
@ -37,7 +39,7 @@ func main() {
|
|||
})
|
||||
|
||||
// Read the md file
|
||||
lines, err := scanLines("../api/Featurecreep.md")
|
||||
lines, err := scanLines(filepath)
|
||||
if err != nil {
|
||||
log.Fatal("Error reading file: ", err)
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue