Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[chore] remove dependabot config for gomod #29472

Merged
merged 4 commits into from
Nov 24, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
remove more dependabot bits
Signed-off-by: Alex Boten <aboten@lightstep.com>
  • Loading branch information
Alex Boten committed Nov 24, 2023
commit 6631c99d84a0e809e237a7d68c3a0c7ff4fd8128
4 changes: 0 additions & 4 deletions .github/workflows/build-and-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -211,10 +211,6 @@ jobs:
run: |
make -j2 generate
git diff --exit-code ':!*go.sum' || (echo 'Generated code is out of date, please run "make generate" and commit the changes in this PR.' && exit 1)
- name: Check gendependabot
run: |
make -j2 gendependabot
git diff --exit-code ':!*go.sum' || (echo 'dependabot.yml is out of date, please run "make gendependabot" and commit the changes in this PR.' && exit 1)
- name: MultimodVerify
run: make multimod-verify
- name: Components dropdown in issue templates
Expand Down
1 change: 0 additions & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,6 @@ When submitting a component to the community, consider breaking it down into sep
* `make genotelcontribcol`
* `make genoteltestbedcol`
* `make generate`
* `make gendependabot`
* `make multimod-verify`
* `make generate-gh-issue-templates`
* **Second PR** should include the concrete implementation of the component. If the
Expand Down
7 changes: 0 additions & 7 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -146,13 +146,6 @@ push-tags: $(MULTIMOD)
git push ${REMOTE} $${tag}; \
done;

DEPENDABOT_PATH=".github/dependabot.yml"
.PHONY: gendependabot
gendependabot:
cd cmd/githubgen && $(GOCMD) install .
githubgen dependabot


# Define a delegation target for each module
.PHONY: $(ALL_MODS)
$(ALL_MODS):
Expand Down
19 changes: 3 additions & 16 deletions cmd/githubgen/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,9 @@ type generator interface {
generate(data *githubData) error
}

// Generates files specific to Github or Dependabot according to status metadata:
// Generates files specific to Github according to status metadata:
// .github/CODEOWNERS
// .github/ALLOWLIST
// .github/dependabot.yml
// .github/ISSUE_TEMPLATES/*.yaml (list of components)
func main() {
folder := flag.String("folder", ".", "folder investigated for codeowners")
Expand All @@ -36,16 +35,14 @@ func main() {
switch arg {
case "issue-templates":
generators = append(generators, issueTemplatesGenerator{})
case "dependabot":
generators = append(generators, dependabotGenerator{})
case "codeowners":
generators = append(generators, codeownersGenerator{})
default:
panic(fmt.Sprintf("Unknown generator: %s", arg))
}
}
if len(generators) == 0 {
generators = []generator{issueTemplatesGenerator{}, dependabotGenerator{}, codeownersGenerator{}}
generators = []generator{issueTemplatesGenerator{}, codeownersGenerator{}}
}
if err := run(*folder, *allowlistFilePath, generators); err != nil {
log.Fatal(err)
Expand Down Expand Up @@ -81,7 +78,6 @@ type githubData struct {
allowlistFilePath string
maxLength int
components map[string]metadata
dependabotData *dependabotData
}

func loadMetadata(filePath string) (metadata, error) {
Expand All @@ -107,12 +103,6 @@ func run(folder string, allowlistFilePath string, generators []generator) error

components := map[string]metadata{}
var foldersList []string
dependabotData := &dependabotData{
Version: 2,
Updates: []dependabotUpdate{
newDependabotUpdate("", 5),
},
}
maxLength := 0
allCodeowners := map[string]struct{}{}
err := filepath.Walk(folder, func(path string, info fs.FileInfo, err error) error {
Expand All @@ -129,9 +119,7 @@ func run(folder string, allowlistFilePath string, generators []generator) error
components[key] = m
foldersList = append(foldersList, key)
_, err = os.Stat(filepath.Join(currentFolder, "go.mod"))
if err == nil { // go.mod file exists.
dependabotData.Updates = append(dependabotData.Updates, newDependabotUpdate(currentFolder, makePriority(m.Status)))
}

for stability := range m.Status.Stability {
if stability == unmaintainedStatus {
// do not account for unmaintained status to change the max length of the component line.
Expand Down Expand Up @@ -167,7 +155,6 @@ func run(folder string, allowlistFilePath string, generators []generator) error
allowlistFilePath: allowlistFilePath,
maxLength: maxLength,
components: components,
dependabotData: dependabotData,
}

for _, g := range generators {
Expand Down
1 change: 0 additions & 1 deletion extension/sigv4authextension/design.md
Original file line number Diff line number Diff line change
Expand Up @@ -563,7 +563,6 @@ Additionally, a few other files will be modified to reflect changes made, for ex
* `go.sum`
* `versions.yaml`
* `.github/CODEOWNERS`
* `.github/dependabot.yml` will be generated with "make dependabot" and not modified directly
* `cmd/configschema/go.mod`
* `internal/components/components.go`
* `internal/components/extensions_test.go`
Loading