package api import ( "git.jmbit.de/jmb/patchman/client/apt" "git.jmbit.de/jmb/patchman/client/common" "git.jmbit.de/jmb/patchman/client/utils" "github.com/gin-gonic/gin" ) func getPackageList(c *gin.Context) { var packageList []common.ListPackage // Get system package manager packages switch utils.GetOSInfo().PackageManager { case "apt": packageList = apt.GetInstalledList() case "zypper": } c.JSON(200, packageList) }