-
-
Notifications
You must be signed in to change notification settings - Fork 287
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(registry): add dart-debug-adapter (#733)
- Loading branch information
1 parent
2381f50
commit 99d1b27
Showing
3 changed files
with
29 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
local Pkg = require "mason-core.package" | ||
local github = require "mason-core.managers.github" | ||
local _ = require "mason-core.functional" | ||
local path = require "mason-core.path" | ||
|
||
return Pkg.new { | ||
name = "dart-debug-adapter", | ||
desc = [[Dart debug adapter sourced from the Dart VSCode extension.]], | ||
homepage = "https://github.com/Dart-Code/Dart-Code", | ||
languages = { Pkg.Lang.Dart }, | ||
categories = { Pkg.Cat.DAP }, | ||
---@async | ||
---@param ctx InstallContext | ||
install = function(ctx) | ||
github | ||
.unzip_release_file({ | ||
repo = "Dart-Code/Dart-Code", | ||
asset_file = _.compose(_.format "dart-code-%s.vsix", _.gsub("^v", "")), | ||
}) | ||
.with_receipt() | ||
ctx.fs:rmrf(path.concat { "extension", "media" }) | ||
ctx:link_bin( | ||
"dart-debug-adapter", | ||
ctx:write_node_exec_wrapper("dart-debug-adapter", path.concat { "extension", "out", "dist", "debug.js" }) | ||
) | ||
end, | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters