mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-06-27 16:35:57 +00:00
models/repo/pushmirror
This commit is contained in:
parent
184e068f37
commit
ef0788461f
1 changed files with 6 additions and 0 deletions
|
@ -32,6 +32,7 @@ type PushMirror struct {
|
||||||
Repo *Repository `xorm:"-"`
|
Repo *Repository `xorm:"-"`
|
||||||
RemoteName string
|
RemoteName string
|
||||||
RemoteAddress string `xorm:"VARCHAR(2048)"`
|
RemoteAddress string `xorm:"VARCHAR(2048)"`
|
||||||
|
BranchFilter string `xorm:"VARCHAR(255)"`
|
||||||
|
|
||||||
// A keypair formatted in OpenSSH format.
|
// A keypair formatted in OpenSSH format.
|
||||||
PublicKey string `xorm:"VARCHAR(100)"`
|
PublicKey string `xorm:"VARCHAR(100)"`
|
||||||
|
@ -122,6 +123,11 @@ func UpdatePushMirrorInterval(ctx context.Context, m *PushMirror) error {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func UpdatePushMirrorBranchFilter(ctx context.Context, m *PushMirror) error {
|
||||||
|
_, err := db.GetEngine(ctx).ID(m.ID).Cols("branch_filter").Update(m)
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
|
||||||
var DeletePushMirrors = deletePushMirrors
|
var DeletePushMirrors = deletePushMirrors
|
||||||
|
|
||||||
func deletePushMirrors(ctx context.Context, opts PushMirrorOptions) error {
|
func deletePushMirrors(ctx context.Context, opts PushMirrorOptions) error {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue