nestjs-api-example icon indicating copy to clipboard operation
nestjs-api-example copied to clipboard

fix(deps): update dependency reflect-metadata to ^0.2.0

Open renovate[bot] opened this issue 10 months ago • 0 comments

Like on GitHub. In repository: ex. top commiters In user: ex. commits by day, daily average of commits, streak

renovate[bot] avatar Mar 30 '24 07:03 renovate[bot]

Thanks your feedback, these are planned around 0.8

unknwon avatar Oct 11 '14 21:10 unknwon

Is this still planned for 0.8 or is it getting pushed to a later version?

carbontwelve avatar Feb 25 '16 11:02 carbontwelve

Apparently pushed to later version, sorry!

unknwon avatar Feb 25 '16 17:02 unknwon

One of these days I might get round to properly learning go and giving a hand.

carbontwelve avatar Feb 26 '16 08:02 carbontwelve

Good for you!

But you might want to choose a easier one...

unknwon avatar Feb 26 '16 16:02 unknwon

I've had a look at this and it seems almost terribly simple to implement (with regards to go-git-module). Performance-wise (at least for git-commands) I don't see any reason to cache it either to be honest...

(all time-related things are ran on the gogs-repo, on a Core i5-3317U @ 1.70GHz )

Top Commtters

$ time git log --format=format:%an | sort | uniq -c | sort -r -n | head -5
   1468 Unknwon
    573 Unknown
    385 无闻
    197 Lunny Xiao
    146 FuXiaoHei
[...]
real    0m0.115s
user    0m0.060s
sys 0m0.017s

which is easy to parse:

var (
  num int
  commiter string
)
fmt.Sscanf(command.StdOut, "[ ]+%d %s", &num, &commiter)
$ time git log --format=format:%an | sort | uniq -c | sort -r -n | head -20
[...]

Though for Gogs we'd need to do sort|uniq|sort|head in Golang, no clue about the performance-hit there)

Commit counting per User (per day, daily average, and streaks)

$ time git --no-pager log --author="Unknwon" --format=%aI 
2016-05-12T14:32:28-04:00
2016-05-12T14:31:06-04:00
2016-05-11T12:19:26-04:00
2016-05-11T12:17:52-04:00
[...]
real    0m0.075s
user    0m0.070s
sys 0m0.000s

That format is ISO8601, so it's easy to parse with

commitTime := time.Parse(input, time.RFC3339)

(RFC3339 is a profile of ISO8601, git uses RFC3339 but say ISO8601...) Sorting time.Time is relatively simple as well

Like with the previous command, we still need to parse and sort in Golang, no clue how that will impact performance, but git sure isn't the bottleneck :laughing:

bkcsoft avatar May 26 '16 02:05 bkcsoft

Hm, looks like developer support for this feature is low but I'd like to add my support for getting this in as well!

stevenleeg avatar Jul 31 '16 19:07 stevenleeg

First off, thanks Unknwon, great project!

The problem with low priority items... they never get to the top of the list.

Like a blown light bulb in a shopping centre, it's only one, and there are always bigger issues, broken doors, heating systems, etc. it never gets replaced.

Sometime, this will just have to get shunted to the top of the list if it's ever going to get done.

Got to say there are higher priority items that I'd like from gogs too, but would suggest a firm milestone being set, so this one gets done.

Stuey2 avatar Oct 31 '17 12:10 Stuey2

I'd like to bump this thread too, just as a reminder that it would be very useful to some of us. I understand there are higher priority items on to-do list, but... It has been 4 years since this request and I bet a whole bunch of high-priority items have come and gone since then, without this ever being touched. Seeing as bkcsoft demonstrated above how easy it is to implement, I would like to remind that this is here.

tgoncuoglu avatar Oct 04 '18 15:10 tgoncuoglu

+1

shaileshsharan98 avatar Oct 04 '18 15:10 shaileshsharan98

+1

mmmeeedddsss avatar Oct 28 '18 20:10 mmmeeedddsss

+1

JustForFunDeveloper avatar Feb 05 '19 09:02 JustForFunDeveloper

I'm creating a PR, the changes are creating 3 pages:

  • Contributors Page
  • Commits Page
  • Code Frequency Page

Here are the comparisons on GIthub vs Gogs:

Contributors Page

image image image

There are many things that can be improved in this page:

  1. Cache, I think this page can be cached to make it faster
  2. I don't know how to make the list of user having 2 columns instead of 1 (I'm bad with CSS)
  3. Can select range by dragging on the main chart (https://stackoverflow.com/questions/42855738/how-do-i-selecting-a-date-range-like-onclick-but-drag-select)
  4. The header formatting on list of user contribution, especially for 21 commits 38 ++ 10 --
  5. Not sure how to implement comma on 1000's, for example 4000 commits, in GIthub it will be written 4,000 commits, not sure the implementation for different language formatting (should pass string or integer in the template)

Commits Page

image image

Code Frequency Page

image image

pikomonde avatar Apr 15 '24 20:04 pikomonde