Files

31 lines
791 B
Python
Raw Permalink Normal View History

+109
2025-02-17 17:05:13 +08:00
from enum import StrEnum
from pydantic import BaseModel
from core.plugin.entities.plugin import PluginDeclaration, PluginInstallationSource
class PluginBundleDependencyType(StrEnum):
Github = PluginInstallationSource.Github.value
Marketplace = PluginInstallationSource.Marketplace.value
Package = PluginInstallationSource.Package.value
+109
2025-02-17 17:05:13 +08:00
class PluginBundleDependency(BaseModel):
+109
2025-02-17 17:05:13 +08:00
class Github(BaseModel):
repo_address: str
repo: str
release: str
packages: str
class Marketplace(BaseModel):
organization: str
plugin: str
version: str
class Package(BaseModel):
unique_identifier: str
manifest: PluginDeclaration
type: PluginBundleDependencyType
+109
2025-02-17 17:05:13 +08:00
value: Github | Marketplace | Package