autogits/bots-common/request_create.go

33 lines
960 B
Go
Raw Normal View History

2024-08-24 16:47:39 +02:00
package common
2024-09-10 18:24:41 +02:00
/*
* This file is part of Autogits.
*
* Copyright © 2024 SUSE LLC
*
* Autogits is free software: you can redistribute it and/or modify it under
* the terms of the GNU General Public License as published by the Free Software
* Foundation, either version 2 of the License, or (at your option) any later
* version.
*
* Autogits is distributed in the hope that it will be useful, but WITHOUT ANY
* WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
* PARTICULAR PURPOSE. See the GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License along with
* Foobar. If not, see <https://www.gnu.org/licenses/>.
*/
2024-08-24 17:20:46 +02:00
type CreateWebhookEvent struct {
2024-08-24 16:47:39 +02:00
Sha string
Ref string // name of tag/branch
Ref_type string // tag, branch
2024-08-27 11:42:48 +02:00
Repository *Repository
Sender *User
2024-08-24 16:47:39 +02:00
}
2024-08-28 00:45:47 +02:00
func (c *CreateWebhookEvent) GetAction() string {
return c.Ref_type
}