This repository was archived by the owner on May 14, 2022. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +28
-3
lines changed Expand file tree Collapse file tree 3 files changed +28
-3
lines changed Original file line number Diff line number Diff line change
1
+ package pluginlib
2
+
3
+ type PackageName struct {
4
+ ApkPackageName string
5
+ }
6
+
7
+ func InstallPackage (packageName PackageName ) <- chan error {
8
+ return StackHeadMain .Execute (IntCmdInstallPkgApk , packageName .ApkPackageName )
9
+ }
10
+
11
+ func UninstallPackage (packageName PackageName ) <- chan error {
12
+ return StackHeadMain .Execute (IntCmdUninstallPkgApk , packageName .ApkPackageName )
13
+ }
Original file line number Diff line number Diff line change 5
5
)
6
6
7
7
type Plugin interface {
8
- Setup ()
9
- Deploy (project Project )
10
- Destroy (project Project )
8
+ Setup () <- chan error
9
+ Deploy (project Project ) <- chan error
10
+ Destroy (project Project ) <- chan error
11
11
TriggerHook (hookName string , project Project )
12
12
}
13
13
Original file line number Diff line number Diff line change
1
+ package pluginlib
2
+
3
+ type IStackHeadMain interface {
4
+ Execute (command string , args ... interface {}) <- chan error
5
+ }
6
+
7
+ const (
8
+ IntCmdInstallPkgApk string = "stackhead:install:package:apk"
9
+ IntCmdUninstallPkgApk string = "stackhead:uninstall:package:apk"
10
+ )
11
+
12
+ var StackHeadMain IStackHeadMain = nil
You can’t perform that action at this time.
0 commit comments