fix generator to work even in nested packer/packer dirs
This commit is contained in:
parent
25f2ec48d3
commit
fa163c2514
|
@ -40,7 +40,8 @@ func main() {
|
||||||
if err != nil {
|
if err != nil {
|
||||||
panic(err)
|
panic(err)
|
||||||
}
|
}
|
||||||
paths := strings.SplitAfter(absFilePath, "packer"+string(os.PathSeparator))
|
paths := strings.Split(absFilePath, "cmd"+string(os.PathSeparator)+
|
||||||
|
"generate-fixer-deprecations"+string(os.PathSeparator)+"main.go")
|
||||||
packerDir := paths[0]
|
packerDir := paths[0]
|
||||||
|
|
||||||
// Load all deprecated options from all active fixers
|
// Load all deprecated options from all active fixers
|
||||||
|
|
Loading…
Reference in New Issue