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

add wechaty/user/images.go #2

Merged
merged 2 commits into from
Mar 15, 2020
Merged

add wechaty/user/images.go #2

merged 2 commits into from
Mar 15, 2020

Conversation

dingdayu
Copy link
Member

Hi, my name is dingdayu.

I'm not very clear about the specifications of the project, such as the title format of the PR, and how to explain the newly added incomplete other interfaces or classes, but luckily this description can be modified.

@CLAassistant
Copy link

CLAassistant commented Mar 15, 2020

CLA assistant check
All committers have signed the CLA.

@dingdayu
Copy link
Member Author

When cross-language, different languages have different package management styles and object-oriented packaging methods, such as GO, I am not sure where to get these instructions.

@dingdayu
Copy link
Member Author

@huan I need you help me.

@huan
Copy link
Member

huan commented Mar 15, 2020

Hello @dingdayu !

It's great to see your Pull Request with the very first translation to the Go Wechaty (#1), your Image class looks good!

Cloud you please move those two directories (/wechaty and the /wechaty-puppet) to /src/, so that we can keep the directory structure aligned to the Wechaty and Python Wechaty project? (if it does not conflict with the Go).

We can merge this PR after you followed the Wechaty directory structure.

Thank you very much for your interest in the Go Wechaty project, and I'm looking forward to seeing more progress from the Go community for using Wechaty!

BTW: About the Go Styles

For the Go language, I'm not very familiar with the package management styles and oo packaging methods. I'd like to suggest that we can just follow the best practice from the Go community, and also follow the existing styles from the Wechaty project.

@dingdayu
Copy link
Member Author

Although I don't really recommend this, it does not go against anything.
I think we will have better practice in the future.

@huan huan merged commit a20758e into wechaty:master Mar 15, 2020
@huan
Copy link
Member

huan commented Mar 15, 2020

Great to see that you have followed the directory structure, good work.

Let's merge this PR for making our first step on lang Go! Cheers! 🍻

@huan
Copy link
Member

huan commented Mar 15, 2020

I have invited you to join the Wechaty Contributor team on GitHub, please accept it.

You've invited 小雨 to Wechaty! They'll be receiving an email shortly. They can also visit https://github.com/wechaty to accept the invitation.

And I noticed that you said "I don't really recommend this", could you please explain it in detail? We can iterate the codebase and our styles in the later commits, as we can keep learning from the community.

@dingdayu
Copy link
Member Author

dingdayu commented Mar 16, 2020

This is not forbidden, But not best practice.

Go recommends putting the code directly in the outer directory. We usually learn from good projects. as kubernetes,coredns.

The most direct manifestation:

import (
	"fmt"

	"github.com/wechaty/go-wechaty/src/wechaty"
)

Excessive directory hierarchy on the import path, src/wechaty be redundant.

Of course, this is controversial in the community, but Go project generally doesn't have src.

@huan
Copy link
Member

huan commented Mar 16, 2020

Ok, I learned that, thanks.

It seems that it's not a big deal, so let's keep the whole Wechaty project aligned first, and we can adjust it when we publish Go Wechaty officially (after ding-dong-bot works).

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