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 last-commit badges to all github repos #3154

Closed
wants to merge 1 commit into from
Closed

Conversation

kpym
Copy link

@kpym kpym commented Jul 4, 2020

Some of the projects are no longer being maintained, others are very active. The last-commit badge makes it easy to distinguish them.

Some of the projects are no longer being maintained, others are very active. The `last-commit` badge makes it easy to distinguish them.
@avelino
Copy link
Owner

avelino commented Jul 4, 2020

Thank you for contributing with awesome-go, we will revise your contribution as soon as possible.

Automation body links content check:

  • godoc.org or pkg.go.dev: True
  • goreportcard.com: False
  • coverage: False

@avelino
Copy link
Owner

avelino commented Jul 5, 2020

This will generate a lot of demand in shields.io at each access, it's not healthy for the project.

Did you make this change via script?
This information may be interesting on awesome-go.com, but not on readme.md

@panjf2000
Copy link
Collaborator

Indeed, adding this kind of badge will result in thousands of additional HTTP requests when visiting awesome-go page, which badly slows down the access speed.

@kpym
Copy link
Author

kpym commented Jul 5, 2020

I've made this by simple search/replace with regular expressions. And I agree that this is not optimal.

Maybe fetching all badges once a day is enough. And store them in a unique sprite image will limit the http access.

@panjf2000
Copy link
Collaborator

panjf2000 commented Jul 5, 2020

The idea of checking out the activities of repositories in awesome-go list makes great sense, but we ought to find the new way instead of adding shield.io badge into README directly, maybe set up a daily script to scan all repositories in README and get the last commits, then write these last-commit dates into README back, as text format, it doesn't have to be image format.

@kpym
Copy link
Author

kpym commented Jul 5, 2020

@panjf2000 Yes it could be text format, but the color is very important IMO because it helps to quickly check how active is the project.

@panjf2000
Copy link
Collaborator

@panjf2000 Yes it could be text format, but the color is very important IMO because it helps to quickly check how active is the project.

Make sense, but we have a long way to go if the final decision is image format, then where should we store those cached images?

@kpym
Copy link
Author

kpym commented Jul 5, 2020

The last-commit is only one of the useful informations that can be fetched from the github API, you can at the same time fetch the number of stars, the number of downloads, ... directly from GitHub (without shield.io). All this once a day and make it available in https://awesome-go.com.

@avelino
Copy link
Owner

avelino commented Jul 8, 2020

My proposal would be to start with text and then evolve to image (since we need to evolve the idea of where to host the images), baby steps.

@kpym can you work on this implementation? I imagine this script (in Go) stay inside scripts folder in the awesome-go repository and run automatically via Github Actions

about awesome-go.com

is hosted on netlify, that is, after PR is accepted travis-ci generates the site (html) and sends to netlify, today everything should be contained in the repository awesome-go

thinking about using images we need to improve this architecture, I believe that object store (aka s3) can help us to host the images generated

@kpym
Copy link
Author

kpym commented Jul 10, 2020

@avelino I'm sorry, but I won't have time to deal with this right now.

Some remarks:

  • I don't think images are necessary for awesome-go.com where you can use arbitrary css to style text elements.
  • Images are only useful for rendering the README on github, but as already mentioned this is far from optimal.
  • On second thought I think the README should be kept as simple as possible and that awesome-go.com should be enriched with informations about git repositories (styled via css), as well as search filters (e.g. to show projects that have more than 5 stars and that were updated less than 3 months ago).

This way awesome-go.com will have a real added value on the README, because currently this is not the case, IMO.

@avelino
Copy link
Owner

avelino commented Jul 10, 2020

I agree, we need to improve awesome-go.com

Too bad you can't contribute awsome-go, we'll always be open to new ideas, when you have time to contribute be very welcome

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants