summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorruki <[email protected]>2023-11-08 23:53:31 +0800
committerruki <[email protected]>2023-11-08 23:53:31 +0800
commitba750b500a475c11e28613bc63384d74b44296d8 (patch)
treef10fe9e5acdf6e508ff6c3af0570c40f8a2e40ca
parentd1e979268f9a1e809d8128c7842ff9ccd677fd62 (diff)
define some apis for xpack
-rw-r--r--xmake/includes/xpack/xmake.lua20
1 files changed, 18 insertions, 2 deletions
diff --git a/xmake/includes/xpack/xmake.lua b/xmake/includes/xpack/xmake.lua
index c812001f1..31e898236 100644
--- a/xmake/includes/xpack/xmake.lua
+++ b/xmake/includes/xpack/xmake.lua
@@ -25,5 +25,21 @@
-- @see https://github.com/xmake-io/xmake/issues/1433
--
--- define package description
-interp_add_scopeapis("xpack.set_description", {kind = "values"})
+-- define apis
+local apis = {
+ values = {
+ -- set package version, we will also use project/target version if it's not configured
+ "xpack.set_version",
+ -- set pacakge homepage url
+ "xpack.set_homepage",
+ -- set package description
+ "xpack.set_description",
+ -- set package license, we will also use target license if it's not configured
+ "xpack.set_license",
+ -- add target names to be packaged
+ "xpack.add_targets"
+ }
+}
+for _, apiname in ipairs(apis.values) do
+ interp_add_scopeapis(apiname, {kind = "values"})
+end