diff options
| author | ruki <[email protected]> | 2025-12-22 22:46:47 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2025-12-22 22:46:47 +0800 |
| commit | a699d95a122367dba7e92b5772430b8b6bf3fa72 (patch) | |
| tree | 9532936986f626ad32fbbd6b7b08ffcbc3c567bd /xmake/core | |
| parent | b626131f4dd8e329718c175a5430cf0b48266a1d (diff) | |
remove load deprecated xmake.lua in repository rootdir
Diffstat (limited to 'xmake/core')
| -rw-r--r-- | xmake/core/package/package.lua | 5 | ||||
| -rw-r--r-- | xmake/core/package/repository.lua | 43 |
2 files changed, 0 insertions, 48 deletions
diff --git a/xmake/core/package/package.lua b/xmake/core/package/package.lua index 4a32bbdf7..780bf6608 100644 --- a/xmake/core/package/package.lua +++ b/xmake/core/package/package.lua @@ -3109,11 +3109,6 @@ function package.load_from_repository(packagename, packagedir, opt) return instance end - -- load repository first for checking the xmake minimal version (deprecated) - local repo = opt.repo - if repo then - repo:load() - end -- find the package script path local scriptpath = opt.packagefile diff --git a/xmake/core/package/repository.lua b/xmake/core/package/repository.lua index 400cd2751..7f140c098 100644 --- a/xmake/core/package/repository.lua +++ b/xmake/core/package/repository.lua @@ -46,18 +46,6 @@ function _instance.new(name, url, branch, directory, is_global) return instance end --- get the repository configure -function _instance:get(name) - - -- load info - local info = self:load() - - -- get if from info - local value = info and info[name] or nil - if value ~= nil then - return value - end -end -- get the repository name function _instance:name() @@ -94,37 +82,6 @@ function _instance:directory() return self._DIRECTORY end --- load the repository info in xmake.lua -function _instance:load() - - -- do not loaded? - if not self._INFO then - - -- attempt to load info from the repository script (xmake.lua) - local scriptpath = path.join(self:directory(), "xmake.lua") - if os.isfile(scriptpath) then - - -- get interpreter - local interp = repository._interpreter() - - -- load script - local ok, errors = interp:load(scriptpath) - if not ok then - os.raise("load repo(%s) failed, " .. errors, self:name()) - end - - -- load repository and disable filter - local results, errors = interp:make(nil, true, false) - if not results then - os.raise("load repo(%s) failed, " .. errors, self:name()) - end - - -- save repository info - self._INFO = results - end - end - return self._INFO -end -- get cache function repository._cache(is_global) |
