Gitea: Display a License tab

Created on 27 Nov 2016  路  18Comments  路  Source: go-gitea/gitea

Like GitHub does. It shows a tab with the project license, so it's immediate to see what it is

kinfeature revieweconfirmed statuneeds-feedback

Most helpful comment

All 18 comments

I don't understand what you want to request, please explain it properly.

Maybe he speak about this?

image

Ah, that makes more sense.

But for a self-hosted server, I seems there is no requirement.

we are no forced to do something like github who scan repo to determine license. maybe just a selectbox field on repo settings page is enough ?

This is something we can integrate at some point, so I moved it to a future milestone

Using something like go-license[1] it'd be fairly simple to implement, just remember to _cache_ the result until the license-file changes (just add another column in the repo-table)

[1] https://github.com/ryanuber/go-license

yes we could add a new field on repo model and update it at each push / merge event.

@0xbaadf00d preferably only update when LICENSE* have been updated ;)

@bkcsoft that may not be always he case... some projects use COPYING for instance

LICENSE files my also not necessarily contain a single license, but a list of licenses for various components

@bamboleeeero-bamboleeeero

some projects use COPYING for instance

How does GitHub handle this?

but a list of licenses for various components

Same here. How does others handle that?

As I see it, it's a new feature, do the smallest amount of work first then extend on that in a later version :)

Github handles this through the gem licensee.

some projects use COPYING for instance

Github scans the root of a project, and matches the files in that directory against a series of regular expressions with scores. High enough and it's treated as a file that likely contains the license text.

but a list of licenses for various components

The first license that Licensee detects and knows about is used. A better solution is being discussed at https://github.com/benbalter/licensee/issues/57

I can agree to @bamboleeeero-bamboleeeero - the filename is not always LICENSE. E.g. LICENSE.txt, LICENSE.md, COPYING are often used too

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs during the next 2 weeks. Thank you for your contributions.

@lunny Any plans to implement this? The library looks promising.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

thehowl picture thehowl  路  3Comments

jonasfranz picture jonasfranz  路  3Comments

internalfx picture internalfx  路  3Comments

kolargol picture kolargol  路  3Comments

tuxfanou picture tuxfanou  路  3Comments