mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2024-11-10 04:05:42 +01:00
f17194ca91
Some checks are pending
/ release (push) Waiting to run
testing / backend-checks (push) Waiting to run
testing / frontend-checks (push) Waiting to run
testing / test-unit (push) Blocked by required conditions
testing / test-remote-cacher (map[image:docker.io/valkey/valkey:7.2.5-alpine3.19 port:6379]) (push) Blocked by required conditions
testing / test-remote-cacher (map[image:ghcr.io/microsoft/garnet-alpine:1.0.14 port:6379]) (push) Blocked by required conditions
testing / test-remote-cacher (map[image:redis:7.2 port:6379]) (push) Blocked by required conditions
testing / test-remote-cacher (map[image:registry.redict.io/redict:7.3.0-scratch port:6379]) (push) Blocked by required conditions
testing / test-mysql (push) Blocked by required conditions
testing / test-pgsql (push) Blocked by required conditions
testing / test-sqlite (push) Blocked by required conditions
testing / security-check (push) Blocked by required conditions
This PR is from https://github.com/go-gitea/gitea/pull/31037 This PR was originally created by @d1nch8g , and the original source code comes from https://ion.lc/core/gitea. This PR adds a package registry for [Arch Linux](https://archlinux.org/) packages with support for package files, [signatures](https://wiki.archlinux.org/title/Pacman/Package_signing), and automatic [pacman-database](https://archlinux.org/pacman/repo-add.8.html) management. Features: 1. Push any ` tar.zst ` package and Gitea sign it. 2. Delete endpoint for specific package version and all related files 3. Supports trust levels with `SigLevel = Required`. 4. Package UI with instructions to connect to the new pacman database and visualised package metadata ![](/attachments/810ca6df-bd20-44c2-bdf7-95e94886d750) You can follow [this tutorial](https://wiki.archlinux.org/title/Creating_packages) to build a *.pkg.tar.zst package for testing docs pr: https://codeberg.org/forgejo/docs/pulls/791 Co-authored-by: d1nch8g@ion.lc Co-authored-by: @KN4CK3R Co-authored-by: @mahlzahn Co-authored-by: @silverwind Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/4785 Reviewed-by: Earl Warren <earl-warren@noreply.codeberg.org> Co-authored-by: Exploding Dragon <explodingfkl@gmail.com> Co-committed-by: Exploding Dragon <explodingfkl@gmail.com>
116 lines
5.4 KiB
Go HTML Template
116 lines
5.4 KiB
Go HTML Template
{{template "base/head" .}}
|
|
<div role="main" aria-label="{{.Title}}" class="page-content repository view issue packages">
|
|
{{template "shared/user/org_profile_avatar" .}}
|
|
<div class="ui container">
|
|
{{template "user/overview/header" .}}
|
|
<div class="issue-title-header">
|
|
<div class="issue-title">
|
|
<h1>{{.PackageDescriptor.Package.Name}} ({{.PackageDescriptor.Version.Version}})</h1>
|
|
</div>
|
|
<div>
|
|
{{$timeStr := TimeSinceUnix .PackageDescriptor.Version.CreatedUnix ctx.Locale}}
|
|
{{if .HasRepositoryAccess}}
|
|
{{ctx.Locale.Tr "packages.published_by_in" $timeStr .PackageDescriptor.Creator.HomeLink .PackageDescriptor.Creator.GetDisplayName .PackageDescriptor.Repository.Link .PackageDescriptor.Repository.FullName}}
|
|
{{else}}
|
|
{{ctx.Locale.Tr "packages.published_by" $timeStr .PackageDescriptor.Creator.HomeLink .PackageDescriptor.Creator.GetDisplayName}}
|
|
{{end}}
|
|
</div>
|
|
</div>
|
|
<div class="issue-content">
|
|
<div class="issue-content-left">
|
|
{{template "package/content/alpine" .}}
|
|
{{template "package/content/arch" .}}
|
|
{{template "package/content/cargo" .}}
|
|
{{template "package/content/chef" .}}
|
|
{{template "package/content/composer" .}}
|
|
{{template "package/content/conan" .}}
|
|
{{template "package/content/conda" .}}
|
|
{{template "package/content/container" .}}
|
|
{{template "package/content/cran" .}}
|
|
{{template "package/content/debian" .}}
|
|
{{template "package/content/generic" .}}
|
|
{{template "package/content/go" .}}
|
|
{{template "package/content/helm" .}}
|
|
{{template "package/content/maven" .}}
|
|
{{template "package/content/npm" .}}
|
|
{{template "package/content/nuget" .}}
|
|
{{template "package/content/pub" .}}
|
|
{{template "package/content/pypi" .}}
|
|
{{template "package/content/rpm" .}}
|
|
{{template "package/content/rubygems" .}}
|
|
{{template "package/content/swift" .}}
|
|
{{template "package/content/vagrant" .}}
|
|
</div>
|
|
<div class="issue-content-right ui segment">
|
|
<strong>{{ctx.Locale.Tr "packages.details"}}</strong>
|
|
<div class="ui relaxed list">
|
|
<div class="item">{{svg .PackageDescriptor.Package.Type.SVGName 16 "tw-mr-2"}} {{.PackageDescriptor.Package.Type.Name}}</div>
|
|
{{if .HasRepositoryAccess}}
|
|
<div class="item">{{svg "octicon-repo" 16 "tw-mr-2"}} <a href="{{.PackageDescriptor.Repository.Link}}">{{.PackageDescriptor.Repository.FullName}}</a></div>
|
|
{{end}}
|
|
<div class="item">{{svg "octicon-calendar" 16 "tw-mr-2"}} {{TimeSinceUnix .PackageDescriptor.Version.CreatedUnix ctx.Locale}}</div>
|
|
<div class="item">{{svg "octicon-download" 16 "tw-mr-2"}} {{.PackageDescriptor.Version.DownloadCount}}</div>
|
|
{{template "package/metadata/alpine" .}}
|
|
{{template "package/metadata/arch" .}}
|
|
{{template "package/metadata/cargo" .}}
|
|
{{template "package/metadata/chef" .}}
|
|
{{template "package/metadata/composer" .}}
|
|
{{template "package/metadata/conan" .}}
|
|
{{template "package/metadata/conda" .}}
|
|
{{template "package/metadata/container" .}}
|
|
{{template "package/metadata/cran" .}}
|
|
{{template "package/metadata/debian" .}}
|
|
{{template "package/metadata/generic" .}}
|
|
{{template "package/metadata/helm" .}}
|
|
{{template "package/metadata/maven" .}}
|
|
{{template "package/metadata/npm" .}}
|
|
{{template "package/metadata/nuget" .}}
|
|
{{template "package/metadata/pub" .}}
|
|
{{template "package/metadata/pypi" .}}
|
|
{{template "package/metadata/rpm" .}}
|
|
{{template "package/metadata/rubygems" .}}
|
|
{{template "package/metadata/swift" .}}
|
|
{{template "package/metadata/vagrant" .}}
|
|
{{if not (and (eq .PackageDescriptor.Package.Type "container") .PackageDescriptor.Metadata.Manifests)}}
|
|
<div class="item">{{svg "octicon-database" 16 "tw-mr-2"}} {{ctx.Locale.TrSize .PackageDescriptor.CalculateBlobSize}}</div>
|
|
{{end}}
|
|
</div>
|
|
{{if not (eq .PackageDescriptor.Package.Type "container")}}
|
|
<div class="divider"></div>
|
|
<strong>{{ctx.Locale.Tr "packages.assets"}} ({{len .PackageDescriptor.Files}})</strong>
|
|
<div class="ui relaxed list">
|
|
{{range .PackageDescriptor.Files}}
|
|
<div class="item">
|
|
<a href="{{$.Link}}/files/{{.File.ID}}">{{.File.Name}}</a>
|
|
<span class="text small file-size">{{ctx.Locale.TrSize .Blob.Size}}</span>
|
|
</div>
|
|
{{end}}
|
|
</div>
|
|
{{end}}
|
|
<div class="divider"></div>
|
|
<strong>{{ctx.Locale.Tr "packages.versions"}} ({{.TotalVersionCount}})</strong>
|
|
<a class="tw-float-right" href="{{$.PackageDescriptor.PackageWebLink}}/versions">{{ctx.Locale.Tr "packages.versions.view_all"}}</a>
|
|
<div class="ui relaxed list">
|
|
{{range .LatestVersions}}
|
|
<div class="item tw-flex">
|
|
<a class="tw-flex-1 gt-ellipsis" title="{{.Version}}" href="{{$.PackageDescriptor.PackageWebLink}}/{{PathEscape .LowerVersion}}">{{.Version}}</a>
|
|
<span class="text small">{{DateTime "short" .CreatedUnix}}</span>
|
|
</div>
|
|
{{end}}
|
|
</div>
|
|
{{if or .CanWritePackages .HasRepositoryAccess}}
|
|
<div class="divider"></div>
|
|
<div class="ui relaxed list">
|
|
{{if .HasRepositoryAccess}}
|
|
<div class="item">{{svg "octicon-issue-opened" 16 "tw-mr-2"}} <a href="{{.PackageDescriptor.Repository.Link}}/issues">{{ctx.Locale.Tr "repo.issues"}}</a></div>
|
|
{{end}}
|
|
{{if .CanWritePackages}}
|
|
<div class="item">{{svg "octicon-tools" 16 "tw-mr-2"}} <a href="{{.Link}}/settings">{{ctx.Locale.Tr "repo.settings"}}</a></div>
|
|
{{end}}
|
|
</div>
|
|
{{end}}
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{{template "base/footer" .}}
|