diff options
author | KN4CK3R <admin@oldschoolhack.me> | 2023-05-22 04:57:49 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-05-22 10:57:49 +0800 |
commit | cdb088cec288a20e14240f86a689dd14f4cd603b (patch) | |
tree | 0a491ea8dcffa22b5b1033d04f5402425fbeb73c /services | |
parent | ec2a01d1e20c0d33c1ea7e362a7dfd5b653dd15f (diff) | |
download | gitea-cdb088cec288a20e14240f86a689dd14f4cd603b.tar.gz gitea-cdb088cec288a20e14240f86a689dd14f4cd603b.zip |
Add CRAN package registry (#22331)
This PR adds a [CRAN](https://cran.r-project.org/) package registry.
![grafik](https://user-images.githubusercontent.com/1666336/210450039-d6fa6f77-20cd-4741-89a8-1624def267f7.png)
Diffstat (limited to 'services')
-rw-r--r-- | services/forms/package_form.go | 2 | ||||
-rw-r--r-- | services/packages/packages.go | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/services/forms/package_form.go b/services/forms/package_form.go index cf8abfb8fb..2f08dfe9f4 100644 --- a/services/forms/package_form.go +++ b/services/forms/package_form.go @@ -15,7 +15,7 @@ import ( type PackageCleanupRuleForm struct { ID int64 Enabled bool - Type string `binding:"Required;In(alpine,cargo,chef,composer,conan,conda,container,debian,generic,go,helm,maven,npm,nuget,pub,pypi,rpm,rubygems,swift,vagrant)"` + Type string `binding:"Required;In(alpine,cargo,chef,composer,conan,conda,container,cran,debian,generic,go,helm,maven,npm,nuget,pub,pypi,rpm,rubygems,swift,vagrant)"` KeepCount int `binding:"In(0,1,5,10,25,50,100)"` KeepPattern string `binding:"RegexPattern"` RemoveDays int `binding:"In(0,7,14,30,60,90,180)"` diff --git a/services/packages/packages.go b/services/packages/packages.go index 9d5ce04a0e..23aa8a5c31 100644 --- a/services/packages/packages.go +++ b/services/packages/packages.go @@ -365,6 +365,8 @@ func CheckSizeQuotaExceeded(ctx context.Context, doer, owner *user_model.User, p typeSpecificSize = setting.Packages.LimitSizeConda case packages_model.TypeContainer: typeSpecificSize = setting.Packages.LimitSizeContainer + case packages_model.TypeCran: + typeSpecificSize = setting.Packages.LimitSizeCran case packages_model.TypeDebian: typeSpecificSize = setting.Packages.LimitSizeDebian case packages_model.TypeGeneric: |