-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathactions.go
More file actions
39 lines (34 loc) · 1.13 KB
/
Copy pathactions.go
File metadata and controls
39 lines (34 loc) · 1.13 KB
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
31
32
33
34
35
36
37
38
39
package actions
import (
"io"
"github.com/nobe4/gh-not/internal/actions/assign"
"github.com/nobe4/gh-not/internal/actions/debug"
"github.com/nobe4/gh-not/internal/actions/done"
"github.com/nobe4/gh-not/internal/actions/hide"
"github.com/nobe4/gh-not/internal/actions/json"
"github.com/nobe4/gh-not/internal/actions/open"
"github.com/nobe4/gh-not/internal/actions/pass"
"github.com/nobe4/gh-not/internal/actions/print"
"github.com/nobe4/gh-not/internal/actions/read"
"github.com/nobe4/gh-not/internal/actions/tag"
"github.com/nobe4/gh-not/internal/gh"
"github.com/nobe4/gh-not/internal/notifications"
)
type Map map[string]Runner
func GetMap(client *gh.Client) Map {
return map[string]Runner{
"pass": &pass.Runner{},
"debug": &debug.Runner{},
"print": &print.Runner{},
"hide": &hide.Runner{},
"read": &read.Runner{Client: client},
"done": &done.Runner{Client: client},
"open": &open.Runner{Client: client},
"assign": &assign.Runner{Client: client},
"json": &json.Runner{},
"tag": &tag.Runner{},
}
}
type Runner interface {
Run(n *notifications.Notification, params []string, out io.Writer) error
}