@@ -71,7 +71,7 @@ in both Neovim and the GUI.
7171To use VS Code as your code editor, you will additionally need:
7272- [ Node JS (tested on 25.0.0)] ( https://nodejs.org/en/download )
7373
74- First, open your VS Code user settings using Command Palette > Preferences: Open User Settings (JSON).
74+ First, open your VS Code user settings using ` Command Palette > Preferences: Open User Settings (JSON) ` .
7575Add the following key:
7676
7777``` json
@@ -107,7 +107,7 @@ With this alias defined, you can now run:
107107codear core/compiler/examples/argon_workspace
108108```
109109
110- Open the ` lib.ar ` file within the workspace. You can then start the GUI by running Command Palette > Argon LSP: Start GUI.
110+ Open the ` lib.ar ` file within the workspace. You can then start the GUI by running ` Command Palette > Argon LSP: Start GUI ` .
111111
112112> [ !WARNING]
113113> If you cannot find the command for starting the GUI but did not notice any obvious errors, you may be on an old version of VS Code.
@@ -202,6 +202,47 @@ After saving, try opening this cell from the GUI by running `:openCell triple_re
202202should be able to constrain the instances relative to one another based on their
203203constituent rectangles.
204204
205+ ## Logs
206+
207+ <!-- TODO: Implement commands to open GUI log -->
208+ Argon writes log messages to ` ~/.local/state/argon/lsp.log ` (LSP server) and ` ~/local/state/argon/gui.log ` (GUI).
209+ Log level can be set using the ` ARGON_LOG ` environment variable
210+ or in editor-specific configuration. If no configuration is specified, only errors will be logged.
211+ Log level configuration follows [ ` RUST_LOG ` ] ( https://docs.rs/tracing-subscriber/latest/tracing_subscriber/fmt/index.html#filtering-events-with-environment-variables ) syntax.
212+
213+ For performance, it is recommended to use ` ARGON_LOG=warn ` or ` ARGON_LOG=error ` unless you are troubleshooting an issue.
214+
215+ ### Neovim
216+
217+ While the LSP is running, you can open the LSP logs using the ` :ArgonLsp log ` command
218+
219+ To configure the log level, you can use the ` vim.g.argon_lsp.log.level ` key:
220+
221+ ``` lua
222+ vim .g .argon_lsp = {
223+ -- ...
224+ log = {
225+ level = " debug"
226+ }
227+ }
228+ ```
229+
230+ The Neovim plugin will supply ` ARGON_LOG=debug ` when starting the LSP server and GUI.
231+
232+ ### VS Code
233+
234+ While the LSP is running, you can open the LSP logs using the ` Command Palette > Argon LSP: Open Log ` command.
235+
236+ To configure the log level, you can use the ` argonLsp.log.level ` key:
237+
238+ ``` json
239+ {
240+ "argonLsp.log.level" : " debug"
241+ }
242+ ```
243+
244+ The VS Code plugin will supply ` ARGON_LOG=debug ` when starting the LSP server and GUI.
245+
205246## Contributing
206247
207248If you'd like to contribute to Argon, please let us know. You can:
@@ -213,7 +254,7 @@ Documentation updates, tests, and bugfixes are always welcome.
213254For larger feature additions, please discuss your ideas with us before implementing them.
214255
215256Contributions can be submitted by opening a pull request against the ` main ` branch
216- of this repository.
257+ of this repository. Developer documentation can be found in the [ ` docs/ ` ] ( docs/developers.md ) folder.
217258
218259Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion
219260in the work by you shall be licensed under the BSD 3-Clause license, without any additional terms or conditions.
0 commit comments