push-to-dokku/config.go

22 lines
433 B
Go
Raw Normal View History

package main
import "os"
type config struct {
HostName string
AppName string
PrivateKey string
LocalBranch string
RemoteBranch string
}
func readConfig() config {
return config{
HostName: os.Getenv("INPUT_HOST"),
AppName: os.Getenv("INPUT_APP"),
PrivateKey: os.Getenv("INPUT_PRIVATE-KEY"),
LocalBranch: os.Getenv("INPUT_SOURCE-BRANCH"),
RemoteBranch: os.Getenv("INPUT_TARGET-BRANCH"),
}
}