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

fix: bind input param to ProtoSearchPath #39

Merged
merged 5 commits into from
Feb 28, 2023

Conversation

rogerogers
Copy link
Collaborator

What type of PR is this?

What this PR does / why we need it (en: English/zh: Chinese):

en: bind input param to ProtoSearchPath
zh: 绑定输入参数到ProtoSearchPath

Which issue(s) this PR fixes:

Fix: #38

Signed-off-by: rogerogers <rogers@rogerogers.com>
@rogerogers rogerogers changed the title fix: input bind ProtoSearchPath fix: bind input param to ProtoSearchPath Feb 24, 2023
Signed-off-by: rogerogers <rogers@rogerogers.com>
Signed-off-by: rogerogers <rogers@rogerogers.com>
@Duslia
Copy link
Member

Duslia commented Feb 27, 2023

I tried your fix. Your fix just makes it not report errors. But it still cannot work correctly. Here I override WriteAnswer method. So when I execute into this logic, it will call this method to bind. But their name cannot be matched. One is protoSearch and the other is proto_search_path. So you need to modify the question name:

Name: "protoSearch",

Signed-off-by: rogerogers <rogers@rogerogers.com>
@Duslia
Copy link
Member

Duslia commented Feb 27, 2023

It seems that registry is also not work. Could you please also add registry.

err = survey.Ask(customConfig(), ca.SliceParam)

if name == ProtoSearchPath {

@rogerogers
Copy link
Collaborator Author

It seems that registry is also not work. Could you please also add registry.

err = survey.Ask(customConfig(), ca.SliceParam)

if name == ProtoSearchPath {

ok

@Duslia Duslia merged commit 516c5b2 into cloudwego:main Feb 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

cwgo init always return error could not find field matching protoSearch
2 participants