Skip to content

Conversation

@ningzio
Copy link
Contributor

@ningzio ningzio commented Aug 31, 2024

this PR fixed the error no matched module when using goctl api inside of a go workspace.

in go workspace, command go list -m -f '{{.GoMod}}' only lists modules declared in go.work, so goctl can't can the go.mod path even it's already initilized if the project is not in go.work.

to fix this, goctl should

  • use go env GOMOD to determine whether the project is a go module.
  • check if the project is inside of a go workspace, if it does, it will use go work use . to add the project to go.work.

@kevwan kevwan requested a review from kesonan September 1, 2024 07:19
@codecov
Copy link

codecov bot commented Sep 1, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 94.55%. Comparing base (8690859) to head (0820a59).
Report is 251 commits behind head on master.

Additional details and impacted files

see 8 files with indirect coverage changes

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


#3420

Copy link
Collaborator

@kesonan kesonan left a comment

Choose a reason for hiding this comment

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

LGTM

@kesonan
Copy link
Collaborator

kesonan commented Feb 5, 2025

Awesome pr!

@kevwan kevwan added this pull request to the merge queue Feb 5, 2025
Merged via the queue into zeromicro:master with commit 77fb271 Feb 5, 2025
6 checks passed
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.

4 participants