Skip to content
This repository has been archived by the owner on Jun 17, 2022. It is now read-only.

Commit

Permalink
add flag to execute plan
Browse files Browse the repository at this point in the history
  • Loading branch information
imsky committed Mar 16, 2018
1 parent dd2fb14 commit da71cbd
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,8 @@ func getObjectMetadata(o runtime.Object) (metav1.Object, apilabels.Set) {
}

func main() {
label := flag.String("l", "", "Label to filter on")
label := flag.String("l", "", "Label to use as filter")
execute := flag.Bool("e", false, "Update cluster objects")

homedir := os.Getenv("HOME")

Expand Down Expand Up @@ -157,5 +158,10 @@ func main() {
}

plan := generatePlan(args, label, clientset)

fmt.Println(plan)

if *execute == true {
executePlan(plan, clientset)
}
}

0 comments on commit da71cbd

Please sign in to comment.