Skip to content

Commit f7f2bce

Browse files
committed
Scaffold Zed extension
1 parent eb59894 commit f7f2bce

37 files changed

Lines changed: 1906 additions & 1 deletion

.github/workflows/editor-adapters.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,3 +46,21 @@ jobs:
4646
run: |
4747
test-explore/clients/emacs/run-tests.ps1 -Suite vbnet `
4848
-VbNetLspDll src\VbNet.LanguageServer.Vb\bin\Debug\net10.0\VbNet.LanguageServer.dll
49+
50+
zed-static:
51+
runs-on: windows-latest
52+
steps:
53+
- uses: actions/checkout@v4
54+
- uses: dtolnay/rust-toolchain@stable
55+
with:
56+
targets: wasm32-wasip1
57+
- name: Verify Zed extension scaffold
58+
shell: pwsh
59+
run: scripts/verify-zed-extension.ps1
60+
- name: Export Zed adapter dry run
61+
shell: pwsh
62+
run: |
63+
adapters/scripts/export-adapter-repos.ps1 `
64+
-ZedRepoPath "$env:RUNNER_TEMP\vbnet-zed" `
65+
-Clean `
66+
-DryRun

adapters/README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ VB.NET language server.
55

66
- `nvim/vbnet-lsp.nvim`: Neovim adapter package snapshot
77
- `emacs/vbnet-eglot`: Emacs `eglot` adapter package snapshot
8+
- `zed/vbnet-zed`: Zed extension package snapshot
89

910
These adapters are validated in `.github/workflows/editor-adapters.yml` and are
1011
intended for editor-native distribution channels.
@@ -17,6 +18,7 @@ Use the export script to mirror snapshots into standalone repositories:
1718
powershell -NoProfile -ExecutionPolicy Bypass -File ./adapters/scripts/export-adapter-repos.ps1 `
1819
-NvimRepoPath ../vbnet-lsp.nvim `
1920
-EmacsRepoPath ../vbnet-eglot `
21+
-ZedRepoPath ../vbnet-zed `
2022
-Clean
2123
```
2224

adapters/scripts/export-adapter-repos.ps1

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
param(
22
[string]$NvimRepoPath = '',
33
[string]$EmacsRepoPath = '',
4+
[string]$ZedRepoPath = '',
45
[switch]$Clean,
56
[switch]$DryRun
67
)
@@ -57,7 +58,14 @@ function Copy-DirectoryContents {
5758
[switch]$DryRun
5859
)
5960

61+
$excludedNames = @('.git', 'target', 'node_modules', '.zed', 'work')
62+
6063
Get-ChildItem -LiteralPath $Source -Force | ForEach-Object {
64+
if ($excludedNames -contains $_.Name) {
65+
Write-Host " Skipping generated/cache path: $($_.FullName)"
66+
return
67+
}
68+
6169
$target = Join-Path $Destination $_.Name
6270
if ($DryRun) {
6371
Write-Host "DRY-RUN copy: $($_.FullName) -> $target"
@@ -114,8 +122,16 @@ if ($EmacsRepoPath -ne '') {
114122
}
115123
}
116124

125+
if ($ZedRepoPath -ne '') {
126+
$tasks += @{
127+
Name = 'vbnet-zed'
128+
Source = Get-FullPath (Join-Path $repoRoot 'adapters\zed\vbnet-zed')
129+
Destination = Get-FullPath $ZedRepoPath
130+
}
131+
}
132+
117133
if ($tasks.Count -eq 0) {
118-
throw "No destination provided. Set -NvimRepoPath and/or -EmacsRepoPath."
134+
throw "No destination provided. Set -NvimRepoPath, -EmacsRepoPath, and/or -ZedRepoPath."
119135
}
120136

121137
foreach ($task in $tasks) {

adapters/zed/vbnet-zed/.gitignore

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
/target/
2+
/.zed/
3+
/work/
4+
*.wasm
5+
*.log
6+
*.tmp

0 commit comments

Comments
 (0)