-
Notifications
You must be signed in to change notification settings - Fork 14
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
Sort by recently added? #2
Comments
Thank you for the idea. The problem here is that the project currently does not save any data for the previous run. So it wouldnt know which projects were added. It could work by generating a json file for every run that includes the date a project was first added. On consecutive runs this json could be read and updated. I will try to find a good solution for this. |
Come to request the same thing! I’d love to be able to check in and see what’s new. Thanks for the great project! |
I implemented a first version of this. You can check it out on https://awweso.me/ Only problem is it doesnt work for the past since there is no data when a project was added. Im considering using the date of the first commit instead since I can query that easily from Github. |
I noticed that as well and created an issue for it. I will follow up over there. |
For now I changed the sort mechanism to use "Recently Created" in general. That data is more easily available since I can get the createdAt field from the Github API. Do you think the "Recently Added" sorting is necessary as well? |
Just updated the demo to v0.6 which is showing "Recently Created". The reason "Recently Added" did not work as expected is because there was no way to determine when a project was first added to Awesome selfhosted (except for maybe going through the commit history). So I could only save the projects of the previous run and check if any new projects were added. This obviously only works for the future, which is why I changed it to "Recently Created" |
I see. I also found this which seems to work good. https://www.trackawesomelist.com/awesome-selfhosted/awesome-selfhosted/ I thought maybe you could get something from this. |
Thats really great! Thanks for the input! Would be fantastic to use that data. I will see how this can be integrated. |
It looks like they use git blame data to determine the date a project was added. So this could be done with a query like this query {
repositoryOwner(login: "awesome-selfhosted") {
repository(name: "awesome-selfhosted") {
defaultRef
... on Commit {
blame(path: "README.md") {
ranges {
startingLine
endingLine
age
commit {
commitedDate
}
}
}
}
}
}
}
}
|
My guess is they track every change of a project not just the addition.
|
I vote for #2. The point of the feature is to be able to learn about new things, not to be able to browse the history of everything. |
I also think that is the most useful feature. Maybe giving every existing project the date of creation of the repo and from then on track when a project was added to the repo. This way the initial projects arent just randomly sorted and you still have the benefit of seeing when new projects are added in the future. |
Sounds reasonable to me! |
How about using the Github API? E.g. https://api.github.com/repos/AdguardTeam/AdGuardHome
And if required for a "recently updated":
or
It would be trivial to extract the data, but I'm unsure what the call limits are for the API. Source: https://mycyberuniverse.com/en-gb/how-know-creation-date-github-repository.html |
Thanks @modem7 for your suggestion. |
Love the site and repo awesome-selfhosted. Is there any chance you can add a filter to sort by most recently added to the repo?
Thank you!
The text was updated successfully, but these errors were encountered: