Summary:
Due to some [most likely transient infra issues](2013794095), the latest release was only partially published.
Bump the extension to trigger a new release.
Reviewed By: alanz
Differential Revision: D89024759
fbshipit-source-id: fce412fee451eb72246c121706108af3ac34d414
Summary:
Several issues were affecting GitHub CI, preventing the extension to be correctly published to the marketplace.
A new release will therefore be necessary, hence the new bump.
Reviewed By: alanz
Differential Revision: D88848737
fbshipit-source-id: f4c31f1bbc5bb3aeec7359c8c8a5d1faeb0c2f9e
Summary:
We already have a `editors` directory with editor-specific packages and configurations. Move the Emacs sample there.
Also reference it from the Emacs installation docs, to make it simpler to find.
Reviewed By: alanz
Differential Revision: D87517087
fbshipit-source-id: 754324de280ec094d6756d8702738d16fbdf268b
Summary:
This diff brings feature parity when it comes to code lenses between `rebar3` and `buck2` projects. Specifically:
* Adds the `openInteractive` command to the OSS extension, which starts a rebar3 shell
* Adds the `debugInteractive` command to the OSS extension, which starts a rebar3 shell in debug mode (no tests are run)
* Adds the `runInteractive` command to the OSS extension, which runs the test in an open shell (either a debugging one or not)
* It enables the "debug" and "interactive" lenses by default
* It adds some extra logging
Reviewed By: alanz
Differential Revision: D82101533
fbshipit-source-id: cb051a1b6a968bc603d81d7045bfd9e34ddb5b73
Summary:
After debugging a test case via the debug lenses in a rebar3 shell, the shell would stay open.
This diff ensures the shell is terminated on test completion.
Reviewed By: jcpetruzza
Differential Revision: D81242618
fbshipit-source-id: 20f0c03665db73262b8de5b5e2f347c73d64b349
Summary: The command should be a path, not a uri. Since this was misconfigured, the debug lens for rebar3 was failing when no custom command was specified.
Reviewed By: jcpetruzza
Differential Revision: D80962151
fbshipit-source-id: f29e697560d48b9eba4687dd1b391c505d32782e
Summary: The license header we use for our Apache + MIT dual licensed projects can be made more explicit. This has not actual implications on licensing, but does clarify what it means for a project to be dual licensed.
Reviewed By: bigfootjon
Differential Revision: D77550482
fbshipit-source-id: 24267af9a7715bfc604b5840ce29776705428516
Summary: Similarly to what we already do for exported functions, highlight exported types with an underscore.
Reviewed By: TD5
Differential Revision: D76540890
fbshipit-source-id: 457b8f9da8848295f05fb2432b8640d957bdba6d
Summary:
* Launch configurations were no longer valid
* Fixed the code to launch rebar3, so that it injects the necessary code to register with the debugger
* Updated documentation
* In the process, made it easier to log from the extension
Pull Request resolved: https://github.com/WhatsApp/erlang-language-platform/pull/96
Reviewed By: alanz
Differential Revision: D75441461
Pulled By: robertoaloi
fbshipit-source-id: 29427ca620989c4280747ff8dd1a01176d9ab029
Summary:
Erlang/OTP 27 introduces Markdown comments. While this makes it in theory simpler to author in-code documentation, the VS Code extension does not yet recognize comments as Markdown.
This change makes VS Code recognize doc blocks as Markdown, using the concept of an [embedded language](https://code.visualstudio.com/api/language-extensions/syntax-highlight-guide#embedded-languages).
This provides features such as:
* Syntax highlighting for italic, bold, code blocks, etc
* Matching parentheses
* Ability to embed Erlang code blocks with syntax highlighting
* Etc
While this simply works(TM), it makes the doc block too evident and distracting:
{F1978476087}
To preserve the look-and-feel of the old edoc-style comment, we override the default colour for the embedded markdown block. This seems to work fine in both light and dark mode and can always be overridden by a user using the `settings.json` file:
```
"editor.tokenColorCustomizations": {
"textMateRules": [
{
"scope": "meta.embedded.block.markdown",
"settings": {
"foreground": "MY_FAVOURITE_COLOUR"
}
}
],
}
```
The change is being upstreamed [here](https://github.com/erlang-ls/grammar/pull/18).
Reviewed By: alanz
Differential Revision: D75152988
fbshipit-source-id: 3922007c13678be99fb27c99e53f8597c7dcba8f
Summary:
* Do not compute EDoc diagnostics by default
* Add a config option to enable them
Reviewed By: michalmuskala
Differential Revision: D74727423
fbshipit-source-id: f40213de4b4e1176bbfc7a85593af0cf1aaf0e1e
Summary:
Update the grammar used to provide syntax highlighting in VS Code to include the latest contributions.
Major changes are:
* Doc/moduledoc attributes showed as comments and not regular strings
* Fixes for verbatim strings
Reviewed By: michalmuskala
Differential Revision: D74242608
fbshipit-source-id: dac26b72123719e607ca12b03de6f0041cd74e5f
Summary:
Adds the ability to restart the ELP server from the VS Code command palette.
Closes#90.
Reviewed By: alanz
Differential Revision: D72441620
fbshipit-source-id: 7346149f6756520c0fa9cc4fccb0488009eccae7
Summary: Bump version from `0.34.0` to `0.35.0`.
Reviewed By: alanz
Differential Revision: D72305672
fbshipit-source-id: 823144a8641309d46bc5e4854518a5af020a3d28
Summary: To release the OSS version of the VS Code extension.
Reviewed By: ilya-klyuchnikov
Differential Revision: D69578829
fbshipit-source-id: 01d0b50e2068323e30e8e943a4ebee0923b8d655
Summary:
This adds a middleware for resolving code actions. The idea is to intercept `CodeAction` requests and, in case a user input is required, an input box is presented to the user to get additional input.
This is useful, for example, in case of a "extract function" or "extract variable" operation, where the user can specify the name of the new function/variable without having to perform a subsequent rename.
Built-in validation is added for atoms and variables
Fixes#76.
Reviewed By: alanz
Differential Revision: D69112486
fbshipit-source-id: 6384c0cce1ff03d350abdc1630ce75b16c3e9bf5
Summary: We define wrapper `npm` tasks for the `tsc` tasks in the `package.json`, following the VS Code extension template. By disabling auto-discovery, we don't get duplicate tasks when starting a debugging session.
Reviewed By: jcpetruzza
Differential Revision: D68437997
fbshipit-source-id: 26b85bdd7ce407e4331677ed0bf442d1af2bfc2a
Summary:
This config allows to open a TS file from the extension and have a "Run extension" debug config already available.
It also adds the client JS files so that stopping at a breakpoint works.
Reviewed By: jcpetruzza
Differential Revision: D68437898
fbshipit-source-id: f5be84b536de524156193b69e348f06092f689a3
Summary: Enable the code lenses mechanism and, specifically, the "run" ones, allowing users to trigger tests from the IDE for `rebar3` and `buck2` projects.
Reviewed By: alanz
Differential Revision: D68438514
fbshipit-source-id: b13d000717e899beb70246cf9b481e5f91c237bc
Summary: Bump to trigger a new build of the OSS VS Code extension for ELP.
Reviewed By: alanz
Differential Revision: D68437508
fbshipit-source-id: a2c688d5f00c5f8a30609275e837ce0b6a0c629b
Summary: * Add a `elp.debugSingle` command, which will eventually be used by the ELP "debug" code lens to start a debugging session for a given testcase.
Reviewed By: alanz
Differential Revision: D68159114
fbshipit-source-id: f0c2396f40518b1dd590eea49c6b300265899d7a
Summary:
* Add support for custom commands, which are registered during activation
* Register a `elp.runSingle` command, used by the ELP Common Test code lens
* Move the configuration to its own file, for easier reuse
Reviewed By: alanz
Differential Revision: D68155846
fbshipit-source-id: 180948f408dd7e9ce3406e2d96b71c420f51c3d2
Summary:
Just a simple refactoring, to make it clear which types and functions are local and which ones are coming from `vscode`.
No functional change.
Reviewed By: alanz
Differential Revision: D68155847
fbshipit-source-id: fbfe8f003b04c2afd82b66e4ff6473cbb11ba5a2
Summary:
The debugger is typically used to troubleshoot a test. Therefore, use the "test" profile by default, so that the test suite itself is already loaded.
The repetition is due to the command being present as:
* A default config that is dynamically added if no launch configuration is available (user clicks on "debug")
* Default values used to created to populate an initial config
* A snippet that the user can use via the "Create Config" UI in VS Code (via Intellisense)
Reviewed By: jcpetruzza
Differential Revision: D68094987
fbshipit-source-id: e31d348e854efc2b101ab466e0b10a47c1dd8ce2
Summary: This entry in the config allows the user to auto-create a basic launch configuration using the VS Code "Add config" button.
Reviewed By: jcpetruzza
Differential Revision: D68019111
fbshipit-source-id: 05c55b4980c45e75f9a169772291414a559350ff
Summary: Fix a typo in the flag name.
Reviewed By: jcpetruzza
Differential Revision: D68019110
fbshipit-source-id: b0ff8b4be5212fdd9d3cd28c94edeebfdabd0a09
Summary: Putting in place the basic logging infra, with a sample log message.
Reviewed By: jcpetruzza
Differential Revision: D68019109
fbshipit-source-id: c3784b99238e15704c2130965892a087e6e52b10
Summary: Without this option, it is not possible to set breakpoints on Erlang files.
Reviewed By: jcpetruzza
Differential Revision: D68016545
fbshipit-source-id: 5e0296dfc1b7a5fe46d4e8f56a83f6c7f395bb1b
Summary: Instead of using plain `erl`, use the more common `rebar3 shell`
Reviewed By: jcpetruzza
Differential Revision: D68016544
fbshipit-source-id: 5513498ef8df3e2acd1a702a88268950082c96d6
Summary: Allow the user to specify a custom Erlang installation directory. This is useful when using a debugger that requires a specialized version of Erlang/OTP.
Reviewed By: jcpetruzza
Differential Revision: D68013698
fbshipit-source-id: 2dcc7d39e7d2c17dc9b38ceddcaa2efd6fd30855
Summary: Basic debugger support for the ELP VS Code extension.
Reviewed By: jcpetruzza
Differential Revision: D67941710
fbshipit-source-id: ee87b30cf267a3bbdfe1fafc0b0c2e0f1050b641
Summary: Now that OTP 27 is rolled out to dev environments, let's enable code coverage by default when running tests via the code lenses.
Reviewed By: alanz
Differential Revision: D66957756
fbshipit-source-id: 12ad58c5844010ddd31367941eb22a056d9dd0fa