Skip to content

Commit

Permalink
move lsp settings to zed project-local settings (#77)
Browse files Browse the repository at this point in the history
zed-industries/zed#17753

Change-Id: I2dce0cad4856b397f12f64ef1db64661265eaddb
  • Loading branch information
oliverlee authored Sep 26, 2024
1 parent a44e469 commit e4caa19
Showing 1 changed file with 57 additions and 56 deletions.
113 changes: 57 additions & 56 deletions .zed/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,65 +28,66 @@
}
]
}
}
// The following LSP settings need to be copied into Zed settings.
},
// This uses the hermetic clangd from the llvm toolchain, but arguments
// may vary due to personal preference.
//
// https://github.com/zed-industries/zed/discussions/6629#discussioncomment-10493418
// https://github.com/zed-industries/zed/issues/4295#issuecomment-2287229162
// "lsp": {
// "clangd": {
// "binary": {
// "path": "./external/llvm18_toolchain_llvm/bin/clangd",
// "arguments": [
// "--function-arg-placeholders=0",
// "--completion-parse=always",
// "--parse-forwarding-functions",
// "--use-dirty-headers",
// "--include-ineligible-results",
// "--header-insertion-decorators",
// "--limit-references=0",
// "--limit-results=0",
// "--rename-file-limit=0",
// "--enable-config"
// ]
// }
// },
// // https://zed.dev/docs/languages/python#settings
// // https://microsoft.github.io/pyright/#/settings
// // https://github.com/zed-industries/zed/discussions/6564#discussioncomment-10570558
// "pyright": {
// "settings": {
// "python": {
// "pythonPath": "./external/python3_host/python"
// },
// "python.analysis": {
// "autoImportCompletions": "true",
// "typeCheckingMode": "off",
// "logLevel": "trace",
// "extraPaths": ["./external/python3_fake_venv/pypi/site-packages"]
// },
// "pyright": {
// "autoImportCompletions": "true"
// }
// }
// },
// "ruff": {
// "binary": {
// // relative paths get appended to ruff path with Zed extension directory
// "path": "/bin/bash",
// "arguments": [
// "-c",
// "./external/ruff_aarch64-darwin/bin/ruff server --preview --verbose"
// ]
// },
// // https://docs.astral.sh/ruff/editors/settings/#configurationpreference
// "initialization_options": {
// "settings": {
// "logLevel": "trace"
// }
// }
// }
// },
"lsp": {
"clangd": {
"binary": {
"path": "./external/llvm18_toolchain_llvm/bin/clangd",
"arguments": [
"--function-arg-placeholders=0",
"--completion-parse=always",
"--parse-forwarding-functions",
"--use-dirty-headers",
"--include-ineligible-results",
"--header-insertion-decorators",
"--header-insertion=iwyu",
"--import-insertions",
"--limit-references=0",
"--limit-results=0",
"--rename-file-limit=0",
"--enable-config"
]
}
},
// https://zed.dev/docs/languages/python#settings
// https://microsoft.github.io/pyright/#/settings
// https://github.com/zed-industries/zed/discussions/6564#discussioncomment-10570558
"pyright": {
"settings": {
"python": {
"pythonPath": "./external/python3_host/python"
},
"python.analysis": {
"autoImportCompletions": "true",
"typeCheckingMode": "off",
"logLevel": "trace",
"extraPaths": ["./external/python3_fake_venv/pypi/site-packages"]
},
"pyright": {
"autoImportCompletions": "true"
}
}
},
"ruff": {
"binary": {
// relative paths get appended to ruff path with Zed extension directory
"path": "/bin/bash",
"arguments": [
"-c",
"./external/ruff_aarch64-darwin/bin/ruff server --preview --verbose"
]
},
// https://docs.astral.sh/ruff/editors/settings/#configurationpreference
"initialization_options": {
"settings": {
"logLevel": "trace"
}
}
}
}
}

0 comments on commit e4caa19

Please sign in to comment.