Browse Source

upgrade

master
parent
commit
24c29a0073
  1. 43
      gitea/gitea.patch
  2. 10
      gitea/gitea.spec

43
gitea/gitea.patch

@ -1,43 +0,0 @@
Index: pkg/mod/github.com/go-openapi/validate@v0.20.2/fixtures/validation/fixture-additional-items
Index: src/github.com/go-gitea/gitea/models/repo.go
--- src/github.com/go-gitea/gitea/models/repo.go.orig 2021-08-05 19:43:23.000000000 +0200
+++ src/github.com/go-gitea/gitea/models/repo.go 2021-08-06 09:18:22.283172000 +0200
@@ -941,11 +941,23 @@
}
if setting.SSH.Port != 22 {
- cl.SSH = fmt.Sprintf("ssh://%s@%s/%s/%s.git", sshUser, net.JoinHostPort(setting.SSH.Domain, strconv.Itoa(setting.SSH.Port)), repo.OwnerName, repoName)
+ if setting.SSH.StartBuiltinServer {
+ cl.SSH = fmt.Sprintf("ssh://%s/%s/%s.git", net.JoinHostPort(setting.SSH.Domain, strconv.Itoa(setting.SSH.Port)), repo.OwnerName, repoName)
+ } else {
+ cl.SSH = fmt.Sprintf("ssh://%s@%s/%s/%s.git", sshUser, net.JoinHostPort(setting.SSH.Domain, strconv.Itoa(setting.SSH.Port)), repo.OwnerName, repoName)
+ }
} else if setting.Repository.UseCompatSSHURI {
- cl.SSH = fmt.Sprintf("ssh://%s@%s/%s/%s.git", sshUser, sshDomain, repo.OwnerName, repoName)
+ if setting.SSH.StartBuiltinServer {
+ cl.SSH = fmt.Sprintf("ssh://%s/%s/%s.git", sshDomain, repo.OwnerName, repoName)
+ } else {
+ cl.SSH = fmt.Sprintf("ssh://%s@%s/%s/%s.git", sshUser, sshDomain, repo.OwnerName, repoName)
+ }
} else {
- cl.SSH = fmt.Sprintf("%s@%s:%s/%s.git", sshUser, sshDomain, repo.OwnerName, repoName)
+ if setting.SSH.StartBuiltinServer {
+ cl.SSH = fmt.Sprintf("%s:%s/%s.git", sshDomain, repo.OwnerName, repoName)
+ } else {
+ cl.SSH = fmt.Sprintf("%s@%s:%s/%s.git", sshUser, sshDomain, repo.OwnerName, repoName)
+ }
}
cl.HTTPS = ComposeHTTPSCloneURL(repo.OwnerName, repoName)
return cl
Index: src/github.com/go-gitea/gitea/models/ssh_key_authorized_keys.go
--- src/github.com/go-gitea/gitea/models/ssh_key_authorized_keys.go.orig 2021-08-05 19:43:23.000000000 +0200
+++ src/github.com/go-gitea/gitea/models/ssh_key_authorized_keys.go 2021-08-07 09:26:05.921313000 +0200
@@ -47,7 +47,7 @@
func AuthorizedStringForKey(key *PublicKey) string {
sb := &strings.Builder{}
_ = setting.SSH.AuthorizedKeysCommandTemplateTemplate.Execute(sb, map[string]interface{}{
- "AppPath": util.ShellEscape(setting.AppPath),
+ "AppPath": util.ShellEscape("@l_prefix@/sbin/gitea-serv"),
"AppWorkPath": util.ShellEscape(setting.AppWorkPath),
"CustomConf": util.ShellEscape(setting.CustomConf),
"CustomPath": util.ShellEscape(setting.CustomPath),

10
gitea/gitea.spec

@ -22,9 +22,9 @@
##
# package information
%define V_gitea_base 1.15.6
%define V_gitea_dist 1.15.6
%define V_gitea_snap 20211029
%define V_gitea_base 1.15.9
%define V_gitea_dist 1.15.9
%define V_gitea_snap 20211231
# package information
Name: gitea
@ -37,7 +37,7 @@ Class: EVAL
Group: Database
License: MIT
Version: %{V_gitea_base}.%{V_gitea_snap}
Release: 20211029
Release: 20211231
# list of sources
Source0: http://download.openpkg.org/components/versioned/gitea/gitea-%{V_gitea_snap}.tar.xz
@ -45,7 +45,6 @@ Source1: rc.gitea
Source2: gitea-serv.c
Source3: gitea-update.sh
Source4: app.ini
Patch0: gitea.patch
# build information
BuildPreReq: OpenPKG, openpkg >= 20160101, go
@ -64,7 +63,6 @@ PreReq: git
%prep
%setup -q -n gitea
%patch -p0
%build
# patch sources

Loading…
Cancel
Save