ma
marcoroth
GitHub
herb
Workspace
GitHub
CI Pipeline Executions
Filtered
Runs
Demo
Insights
Compare tasks
Analytics
Sign in
Toggle sidebar
Overview
⌘K
Distributed computation caching and task execution are currently disabled for this organization.
herb
Loading workspace stats
Loading workspace insights...
Statistics interval
7 days
30 days
Latest CI Pipeline Executions
Status
Fix filter
Filter
Fuzzy
Filter range
Sort by
Sort by
Start time
Sort ascending
Sort descending
Succeeded
engine/lazy-project-path
99306285 Engine: Compute the project path lazily This pull request stops `VisitorContext` from asking the operating system where it is for every template it builds a context for. `coerce_project_path` falls back to `Pathname.new(Dir.pwd)` when no project path is given, and it ran during construction. The project path is only read when a visitor, a diagnostic, an overlay or the relative file path asks for it, so a template compiled without any of those still paid for a `getcwd` and two allocations. Deriving it on demand takes about 7% off compile time over the `examples/` corpus, measured A/B interleaved against `main`. The value is unchanged. `coerce_project_path` keeps its behavior for a caller that passes a path, and the derived one is cached through the same mutable holder #2262 introduced for the relative file path, so the context can stay frozen. Follow-up to #2262, which left this the last eagerly computed field on the context.
by Marco Roth
M
Succeeded
engine/lazy-project-path
49eec1bc Language Server: Fix opening `.herb.yml` in remote workspaces (#2305) This pull request fixes the `.herb.yml` quick fixes opening a file that does not exist whenever the editor is attached to a remote workspace, like a devcontainer, an SSH host, or WSL. Picking "Disable `<rule>` in `.herb.yml`" wrote the change correctly and then opened a second tab reporting "The editor could not be opened because the file was not found", pointing at the same config file that was already open in another tab. The code action carried a `vscode.open` command with the config URI as a plain string: ```ts command: { title: 'Open .herb.yml', command: 'vscode.open', arguments: [`file://${configPath}`] } ``` In a remote window the extension host works in `file://` paths, and VS Code rewrites them to `vscode-remote://` on the way to the UI. That rewrite only reaches real `Uri` objects. Command arguments travel as raw JSON, so the string passed through untouched and the UI went looking for `/workspaces/<project>/.herb.yml` on the local machine, where nothing of the sort exists. The edit half of the same code action landed on the right file, because `vscode-languageclient` runs workspace edits through `Uri.parse` before applying them. One path converted the URI, the other handed it over as a string. The action now carries `herb.openDocument`, a server command declared through `executeCommandProvider`. Its handler asks the client to open the file with `window/showDocument`, which runs the URI through the same converter the workspace edit was already using. `vscode.open` was also a VS Code command sitting in a server that ships to eight editors, so this affordance never did anything in Neovim, Helix, Zed, or Sublime. `window/showDocument` is part of the protocol, so those clients get it now as well. Clients that cannot open a document are no longer left with nothing. When the client does not advertise `window/showDocument`, or tries to open the file and reports back that it failed, the server falls back to an information message naming the file it changed. Resolves https://github.com/marcoroth/herb/issues/1414
by Marco Roth
M
Previous
Next