-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathevent.go
More file actions
30 lines (27 loc) · 843 Bytes
/
event.go
File metadata and controls
30 lines (27 loc) · 843 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
package main
// RepositoryUpdateEvent is the event type name for a GitLab repository update
// event.
const RepositoryUpdateEvent = "repository_update"
// RepositoryUpdate is a type of event regarding an update to a GitLab
// repository.
type RepositoryUpdate struct {
Name string `json:"event_name"`
Project struct {
Name string `json:"name"`
Description string `json:"description"`
URL string `json:"url"`
SSHURL string `json:"ssh_url"`
Namespace string `json:"namespace"`
} `json:"project"`
Changes []struct {
Before string `json:"before"`
After string `json:"after"`
Ref string `json:"ref"`
} `json:"changes"`
Refs []string `json:"refs"`
}
// Event is the base event type, used to figure out what event type the message
// holds.
type Event struct {
Name string `json:"event_name"`
}