aboutsummaryrefslogtreecommitdiffstats
path: root/lua/mason-core/path.lua
diff options
context:
space:
mode:
authorWilliam Boman <william@redwill.se>2023-10-13 01:53:41 +0200
committerWilliam Boman <william@redwill.se>2025-02-19 09:23:19 +0100
commitf1e58d3ce7ab3bdb3036b791811896a0220703ad (patch)
treece44529583dcf72844b206fe8578f0ada5ef153f /lua/mason-core/path.lua
parentrefactor(installer): move initializations to InstallContext constructor (diff)
downloadmason-f1e58d3ce7ab3bdb3036b791811896a0220703ad.tar
mason-f1e58d3ce7ab3bdb3036b791811896a0220703ad.tar.gz
mason-f1e58d3ce7ab3bdb3036b791811896a0220703ad.tar.bz2
mason-f1e58d3ce7ab3bdb3036b791811896a0220703ad.tar.lz
mason-f1e58d3ce7ab3bdb3036b791811896a0220703ad.tar.xz
mason-f1e58d3ce7ab3bdb3036b791811896a0220703ad.tar.zst
mason-f1e58d3ce7ab3bdb3036b791811896a0220703ad.zip
refactor(path): use InstallLocation to produce paths, remove static path methods
Diffstat (limited to 'lua/mason-core/path.lua')
-rw-r--r--lua/mason-core/path.lua40
1 files changed, 0 insertions, 40 deletions
diff --git a/lua/mason-core/path.lua b/lua/mason-core/path.lua
index 3d7c8668..9eeed3ba 100644
--- a/lua/mason-core/path.lua
+++ b/lua/mason-core/path.lua
@@ -27,44 +27,4 @@ function M.is_subdirectory(root_path, path)
return root_path == path or path:sub(1, #root_path + 1) == root_path .. sep
end
----@param dir string?
-function M.install_prefix(dir)
- local settings = require "mason.settings"
- return M.concat { settings.current.install_root_dir, dir }
-end
-
----@param executable string?
-function M.bin_prefix(executable)
- return M.concat { M.install_prefix "bin", executable }
-end
-
----@param file string?
-function M.share_prefix(file)
- return M.concat { M.install_prefix "share", file }
-end
-
----@param file string?
-function M.opt_prefix(file)
- return M.concat { M.install_prefix "opt", file }
-end
-
----@param name string?
-function M.package_prefix(name)
- return M.concat { M.install_prefix "packages", name }
-end
-
----@param name string?
-function M.package_build_prefix(name)
- return M.concat { M.install_prefix "staging", name }
-end
-
----@param name string
-function M.package_lock(name)
- return M.package_build_prefix(("%s.lock"):format(name))
-end
-
-function M.registry_prefix()
- return M.install_prefix "registries"
-end
-
return M