Skip to content

Commit a416d48

Browse files
committed
chore: debug
1 parent f059f9d commit a416d48

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

main.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import (
66
"io"
77
"os"
88
"path/filepath"
9+
"runtime"
910
"slices"
1011
"sort"
1112
"strings"
@@ -587,6 +588,9 @@ This flag can be passed multiple times to ignore different vulnerabilities`)
587588
loadLocalConfig = false
588589
}
589590

591+
if runtime.GOOS == "windows" {
592+
r.PrintTextf("reading lockfiles")
593+
}
590594
files := readAllLockfiles(r, pathsToLocksWithParseAs, cli.Args(), loadLocalConfig, &config)
591595

592596
files.adjustExtraDatabases(*noConfigDatabases, *useAPI, *useDatabases)

pkg/lockfile/extract.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,9 +92,12 @@ func createScanInput(path string, root string, fileInfo fs.FileInfo) (*filesyste
9292
// On Windows, it will most likely be the drive (e.g. C:\)
9393
func getRootDir(path string) string {
9494
if runtime.GOOS == "windows" {
95+
fmt.Printf("we are on windows so returning %s\n", filepath.VolumeName(path))
9596
return filepath.VolumeName(path) + "\\"
9697
}
9798

99+
fmt.Printf("we are not on Windows\n")
100+
98101
if strings.HasPrefix(path, "/") {
99102
return "/"
100103
}

0 commit comments

Comments
 (0)