mirror of
https://github.com/AvengeMedia/DankMaterialShell.git
synced 2026-08-02 11:38:30 -04:00
0cdb065739
binary to mount at runtime, -c or DMS_SHELL_DIR overrides required to explicitly override embedded configuration
27 lines
606 B
Go
27 lines
606 B
Go
package plugins
|
|
|
|
import (
|
|
"fmt"
|
|
|
|
"github.com/AvengeMedia/DankMaterialShell/core/internal/server/models"
|
|
)
|
|
|
|
func HandleRequest(conn *models.Conn, req models.Request) {
|
|
switch req.Method {
|
|
case "plugins.list":
|
|
HandleList(conn, req)
|
|
case "plugins.listInstalled":
|
|
HandleListInstalled(conn, req)
|
|
case "plugins.install":
|
|
HandleInstall(conn, req)
|
|
case "plugins.uninstall":
|
|
HandleUninstall(conn, req)
|
|
case "plugins.update":
|
|
HandleUpdate(conn, req)
|
|
case "plugins.search":
|
|
HandleSearch(conn, req)
|
|
default:
|
|
models.RespondError(conn, req.ID, fmt.Sprintf("unknown method: %s", req.Method))
|
|
}
|
|
}
|