aboutsummaryrefslogtreecommitdiffstats
path: root/lua/mason-registry/sources/github.lua
Commit message (Collapse)AuthorAgeFilesLines
* feat: add support for removal of packages from a registryfix/support-removed-packagesWilliam Boman6 days1-1/+0
| | | | | | | | | | | | This adds support for removal of packages from any given registry. Currently mason.nvim doesn't support this at all and throws an error when trying to interact with the registry in any way while having a removed package installed locally. This ensures that removed packages are available both in the `:Mason` UI as well as the public Lua APIs. These "synthesized" packages only supports uninstallation, and metadata such as licenses, categories, homepage, etc is not available.
* fix(registry): ensure there's no duplicate registry entries (#1957)William Boman2025-05-191-0/+5
|
* feat: associate package instances with registry source and record it in receiptWilliam Boman2025-05-061-1/+12
|
* refactor(registry): refactor registry initializationWilliam Boman2025-03-031-12/+8
|
* refactor!: change Package APIWilliam Boman2025-02-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This changes the following public APIs: **(_breaking_) Events on the `Package` class** The `uninstall:success` event on the `Package` class now receives an `InstallReceipt` as argument, instead of an `InstallHandle`. This receipt is an in-memory representation of what was uninstalled. There's also a new `uninstall:failed` event for situations where uninstallation for some reason fails. Note: this also applies to the registry events (i.e. `package:uninstall:success` and `package:uninstall:failed`). --- **(_breaking_) `Package:uninstall()` is now asynchronous and receives two new arguments, similarly to `Package:install()`** While package uninstallations remain synchronous under the hood, the public API has been changed from synchronous -> asynchronous. Users of this method are recommended to provide a callback in situations where code needs to execute after uninstallation fully completes. --- **(_breaking_) `Package:get_install_path()` has been removed. --- **`Package:install()` now takes an optional callback** This callback allows consumers to be informed whether installation was successful or not without having to go through a different, low-level, API. See below for a comparison between the old and new APIs: ```lua -- before local handle = pkg:install() handle:once("closed", function () -- ... end) -- after pkg:install({}, function (success, result) -- ... end) ```
* refactor: standardize constructors and improve inheritance constructionWilliam Boman2025-02-191-8/+10
|
* refactor(path): use InstallLocation to produce paths, remove static path methodsWilliam Boman2025-02-191-1/+2
|
* feat(registry): add file: source protocol (#1457)William Boman2023-08-261-40/+5
|
* fix(sources): don't skip installation if fixed version is not currently ↵William Boman2023-05-111-2/+2
| | | | installed (#1297)
* feat(registry): add .get_all_package_specs() (#1247)William Boman2023-04-221-19/+30
| | | | This is a faster method than .get_all_packages() due to the fact that it only loads package specifications without instantiating mason-core.package instances. Useful for situations where one only needs to read spec data.
* fix(windows): download registry archive to file instead of piping data (#1189)William Boman2023-04-071-5/+7
| | | | Accessing binary data from the stdout of pwsh.exe's iwr seems to be causing data corruption leading to inability to unpack the archive.
* feat: vendor zzlib for unzip (#1174)William Boman2023-04-031-26/+13
| | | Download data of the registry suggest that ~10-18% struggle to unpack the registry archive, with the drop-off occurring in the `unzip` step. Being able to unpack the registry is a very crucial component of mason.nvim, which warrants vendoring [zzlib](https://github.com/zerkman/zzlib) to allow unpacking it entirely in Lua.
* feat(ui): display warning and error message if registry is not installed (#1164)William Boman2023-04-011-1/+5
|
* refactor: download checksum after unzip (#1135)William Boman2023-03-251-8/+7
| | | | | | | | | * refactor: download checksum after unzip * fixup --------- Co-authored-by: williambotman[bot] <william+bot@redwill.se>
* fix(sources): also set .desc property when updating spec (#1095)William Boman2023-03-141-2/+11
|
* style: enforce import order (#1092)William Boman2023-03-121-9/+9
| | | | | * chore(workflows): update dependencies * style: enforce import order
* feat: add github registry source capabilities (#1091)William Boman2023-03-121-0/+195