diff options
| author | William Boman <william@redwill.se> | 2023-04-11 03:12:52 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-04-11 03:12:52 +0200 |
| commit | e5bb23fa9ee2a2047368b05f262de6b2152d7a27 (patch) | |
| tree | 1265e826e89e92a493e37c85385a77fcf6089b2c /lua/mason-registry/index/tectonic/init.lua | |
| parent | feat(registry): pcall require Lua registry packages (#1200) (diff) | |
| download | mason-e5bb23fa9ee2a2047368b05f262de6b2152d7a27.tar mason-e5bb23fa9ee2a2047368b05f262de6b2152d7a27.tar.gz mason-e5bb23fa9ee2a2047368b05f262de6b2152d7a27.tar.bz2 mason-e5bb23fa9ee2a2047368b05f262de6b2152d7a27.tar.lz mason-e5bb23fa9ee2a2047368b05f262de6b2152d7a27.tar.xz mason-e5bb23fa9ee2a2047368b05f262de6b2152d7a27.tar.zst mason-e5bb23fa9ee2a2047368b05f262de6b2152d7a27.zip | |
chore: migrate packages (#1203)
Diffstat (limited to 'lua/mason-registry/index/tectonic/init.lua')
| -rw-r--r-- | lua/mason-registry/index/tectonic/init.lua | 62 |
1 files changed, 0 insertions, 62 deletions
diff --git a/lua/mason-registry/index/tectonic/init.lua b/lua/mason-registry/index/tectonic/init.lua deleted file mode 100644 index c2bbaade..00000000 --- a/lua/mason-registry/index/tectonic/init.lua +++ /dev/null @@ -1,62 +0,0 @@ -local Optional = require "mason-core.optional" -local Pkg = require "mason-core.package" -local _ = require "mason-core.functional" -local github = require "mason-core.managers.github" -local platform = require "mason-core.platform" -local std = require "mason-core.managers.std" - -local coalesce, when = _.coalesce, _.when - -return Pkg.new { - name = "tectonic", - desc = [[Tectonic is a modernized, complete, self-contained TeX/LaTeX engine, powered by XeTeX and TeXLive.]], - homepage = "https://tectonic-typesetting.github.io", - languages = { Pkg.Lang.LaTeX }, - categories = { Pkg.Cat.Compiler }, - ---@async - ---@param ctx InstallContext - install = function(ctx) - local repo = "tectonic-typesetting/tectonic" - local function format_release_file(file) - return _.compose(_.format(file), _.gsub("^tectonic@", "")) - end - - platform.when { - unix = function() - github - .untargz_release_file({ - repo = repo, - version = Optional.of "tectonic@0.12.0", - asset_file = coalesce( - when(platform.is.mac_x64, format_release_file "tectonic-%s-x86_64-apple-darwin.tar.gz"), - when(platform.is.mac_arm64, format_release_file "tectonic-%s-aarch64-apple-darwin.tar.gz"), - when( - platform.is.linux_x64_gnu, - format_release_file "tectonic-%s-x86_64-unknown-linux-gnu.tar.gz" - ), - when( - platform.is.linux_x64, - format_release_file "tectonic-%s-x86_64-unknown-linux-musl.tar.gz" - ), - when( - platform.is.linux_arm, - format_release_file "tectonic-%s-arm-unknown-linux-musleabihf.tar.gz" - ) - ), - }) - .with_receipt() - std.chmod("+x", { "tectonic" }) - ctx:link_bin("tectonic", "tectonic") - end, - win = function() - github - .unzip_release_file({ - repo = repo, - asset_file = format_release_file "tectonic-%s-x86_64-pc-windows-msvc.zip", - }) - .with_receipt() - ctx:link_bin("tectonic", "tectonic.exe") - end, - } - end, -} |
