Skip to content

Commit 0efa38d

Browse files
committed
chore: add String() to Target
1 parent d528f6d commit 0efa38d

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

scan/target.go

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,15 @@ func (r RepositoryTarget) GetRepositoryUrl() string {
1919
return r.repositoryUrl
2020
}
2121

22+
func (r RepositoryTarget) String() string {
23+
result := "[path=" + r.LocalFilePath
24+
if r.repositoryUrl != "" {
25+
result += "; repository=" + r.repositoryUrl
26+
}
27+
result += "]"
28+
return result
29+
}
30+
2231
type TargetOptions func(*RepositoryTarget) error
2332

2433
func WithRepositoryUrl(repositoryUrl string) TargetOptions {

0 commit comments

Comments
 (0)