1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-15 03:14:23 +00:00
freebsd-ports/security/vuls/files/patch-subcmds_configtest.go
Rainer Hurling de7c95c2ca security/vuls: Update to 0.9.0
This patch updates from v0.6.1 to only v0.9.0 [1] for
a smooth upgrade experience. The next one will update
from 0.9.0 to 0.13.7 [2].

[1] https://github.com/future-architect/vuls/releases/tag/v0.9.0
[2] https://github.com/future-architect/vuls/releases

PR:		251654
Submitted by:	Alexandru Ciobanu <iscandr@gmail.com> (maintainer)
Approved by:	tcberner (mentor)
2020-12-08 11:26:57 +00:00

23 lines
621 B
Go

--- subcmds/configtest.go.orig 2020-11-27 21:39:52 UTC
+++ subcmds/configtest.go
@@ -4,8 +4,7 @@ import (
"context"
"flag"
"fmt"
- "os"
- "path/filepath"
+ "path/filepath"
"strings"
"github.com/google/subcommands"
@@ -48,8 +47,7 @@ func (*ConfigtestCmd) Usage() string {
// SetFlags set flag
func (p *ConfigtestCmd) SetFlags(f *flag.FlagSet) {
- wd, _ := os.Getwd()
- defaultConfPath := filepath.Join(wd, "config.toml")
+ defaultConfPath := filepath.Join("%%ETCDIR%%", "config.toml")
f.StringVar(&p.configPath, "config", defaultConfPath, "/path/to/toml")
defaultLogDir := util.GetDefaultLogDir()