Plugins: Simplify plugin file removal (#66115)

* make explicit class check when attempting to remove plugin

* simplify plugin file tracking

* fix test

* apply feedback

* fix linter
This commit is contained in:
Will Browne
2023-04-20 11:52:59 +02:00
committed by GitHub
parent 6e8b17efd8
commit 739c7f1c68
15 changed files with 193 additions and 281 deletions
+7 -7
View File
@@ -22,27 +22,27 @@ type Dependency struct {
Version string
}
type InstalledPlugin struct {
type installedPlugin struct {
ID string `json:"id"`
Name string `json:"name"`
Type string `json:"type"`
Info PluginInfo `json:"info"`
Dependencies Dependencies `json:"dependencies"`
Info pluginInfo `json:"info"`
Dependencies dependencies `json:"dependencies"`
}
type Dependencies struct {
type dependencies struct {
GrafanaVersion string `json:"grafanaVersion"`
Plugins []PluginDependency `json:"plugins"`
Plugins []pluginDependency `json:"plugins"`
}
type PluginDependency struct {
type pluginDependency struct {
ID string `json:"id"`
Type string `json:"type"`
Name string `json:"name"`
Version string `json:"version"`
}
type PluginInfo struct {
type pluginInfo struct {
Version string `json:"version"`
Updated string `json:"updated"`
}