mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2025-01-22 15:18:43 +00:00
godotenv use autoload everywhere (#548)
This commit is contained in:
parent
e072e4cce7
commit
88236d8d59
1 changed files with 1 additions and 5 deletions
|
@ -18,17 +18,13 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"os"
|
"os"
|
||||||
|
|
||||||
"github.com/joho/godotenv"
|
_ "github.com/joho/godotenv/autoload"
|
||||||
"github.com/rs/zerolog/log"
|
|
||||||
"github.com/urfave/cli/v2"
|
"github.com/urfave/cli/v2"
|
||||||
|
|
||||||
"github.com/woodpecker-ci/woodpecker/version"
|
"github.com/woodpecker-ci/woodpecker/version"
|
||||||
)
|
)
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
if err := godotenv.Load(".env"); err != nil {
|
|
||||||
log.Error().Err(err).Msg("load godotenv failed")
|
|
||||||
}
|
|
||||||
app := cli.NewApp()
|
app := cli.NewApp()
|
||||||
app.Name = "woodpecker-server"
|
app.Name = "woodpecker-server"
|
||||||
app.Version = version.String()
|
app.Version = version.String()
|
||||||
|
|
Loading…
Reference in a new issue