Justo plugin for OS package managers. APK and APT supported. All tasks are local and SSH-compatible.
Developed in Dogma, compiled to JavaScript.
Proudly made with ♥ in Valencia, Spain, EU.
const pkg = require("justo.plugin.pkg");
This task updates the local index:
pkg.update()
These tasks install one or multiple packages:
pkg.add({pkg, allowUntrusted, allowUnauthenticated, reinstall})
pkg.install({pkg, allowUntrusted, allowUnauthenticated, reinstall})
-
pkg
(string or string[], required). Package(s) to install. -
allowUntrusted
andallowUnauthorized
(bool). Allow to install untrusted packages. -
reinstall
(bool). Reinstall the package(s)? Only for APT.
Example:
pkg.add({pkg: "lua5.3"})
This task checks if a package is installed:
pkg.installed({pkg}) : bool
-
pkg
(string, required). Package to check.
Example:
if (!pkg.installed({pkg: "lua5.3"})) {
pkg.add({pkg: "lua5.3"});
}
This task checks if a package is available to install:
pkg.available({pkg}) : bool
-
pkg
(string, required). Package to check.
Example:
if (!pkg.installed({pkg: "lua5.3"}) && pkg.available({pkg: "lua5.3"})) {
pkg.add({pkg: "lua5.3"})
}
These tasks remove one or multiple packages:
pkg.del({pkg})
pkg.remove({pkg})
-
pkg
(string or string[], required). Package(s) to remove.
Example:
pkg.del({pkg: "lua5.3"});