Skip to content
This repository has been archived by the owner on Jan 26, 2020. It is now read-only.

Commit

Permalink
Merge pull request #38 from ixdy/rules_go-load
Browse files Browse the repository at this point in the history
Delete the rules_go load rule if it's not needed
  • Loading branch information
ixdy committed Apr 24, 2017
2 parents 0769f2a + 821d981 commit 9a0b26c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions gazel/gazel.go
Original file line number Diff line number Diff line change
Expand Up @@ -690,6 +690,10 @@ func reconcileLoad(f *bzl.File, rules []*bzl.Rule) {
if args[0] != goRulesLabel {
continue
}
if len(usedRuleKindsList) == 0 {
f.DelRules(r.Kind(), r.Name())
continue
}
r.Call.List = asExpr(append(
[]string{goRulesLabel}, usedRuleKindsList...,
)).(*bzl.ListExpr).List
Expand Down

0 comments on commit 9a0b26c

Please sign in to comment.