From: Sergey Matveev Date: Sun, 27 Feb 2022 11:36:35 +0000 (+0300) Subject: Do not print target of the self in -dot X-Git-Tag: v1.24.0~2 X-Git-Url: http://www.git.cypherpunks.ru/?p=goredo.git;a=commitdiff_plain;h=d416a365ca4df6e99fced318033d34be4407ecfb Do not print target of the self in -dot --- diff --git a/dot.go b/dot.go index d1433b5..33f5d85 100644 --- a/dot.go +++ b/dot.go @@ -57,8 +57,11 @@ func dotWalker(data map[DotNodes]bool, tgtOrig string) (map[DotNodes]bool, error data[DotNodes{tgtOrig, cwdMustRel(cwd, m["Target"])}] = true case DepTypeIfchange: dep = m["Target"] + if dep == tgt { + continue + } data[DotNodes{tgtOrig, cwdMustRel(cwd, dep)}] = false - if isSrc(cwd, dep) || dep == tgt { + if isSrc(cwd, dep) { continue } data, err = dotWalker(data, cwdMustRel(cwd, dep)) diff --git a/usage.go b/usage.go index 3625634..2c9b1a0 100644 --- a/usage.go +++ b/usage.go @@ -24,7 +24,7 @@ import ( ) const ( - Version = "1.23.0" + Version = "1.24.0" Warranty = `Copyright (C) 2020-2022 Sergey Matveev This program is free software: you can redistribute it and/or modify