Skip to content

Gazelle support for buf_push - #25

Merged
srikrsna-buf merged 3 commits into
mainfrom
buf-push-gazelle
Dec 28, 2022
Merged

srikrsna-buf merged 3 commits into
mainfrom
buf-push-gazelle

Conversation

@srikrsna-buf

Copy link
Copy Markdown
Contributor

Depends on #24.

@srikrsna-buf
srikrsna-buf marked this pull request as ready for review August 8, 2022 17:03
Comment thread gazelle/buf/generate.go Outdated

func generatePushRule() *rule.Rule {
r := rule.NewRule(pushRuleKind, "buf_push")
r.SetAttr("targets", []string{":buf"})

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why this default, isn't it always overridden after resolving?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removing it

Comment thread gazelle/buf/kinds.go Outdated
},
},
pushRuleKind: {
MatchAttrs: []string{"name"},

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

breakingRuleKind: {
		MatchAttrs: []string{"targets"},

Since these rules treat targets the same way and share code related to resolving, should their matchattrs be the same?

@srikrsna-buf
srikrsna-buf merged commit 0318da1 into main Dec 28, 2022
@srikrsna-buf
srikrsna-buf deleted the buf-push-gazelle branch December 28, 2022 10:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants