Skip to content

Commit

Permalink
Add Zed config.
Browse files Browse the repository at this point in the history
  • Loading branch information
CathalMullan committed Nov 16, 2024
1 parent 490e34c commit c55c7fe
Show file tree
Hide file tree
Showing 3 changed files with 58 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .vscode/extensions.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,6 @@

// Nix
"mkhl.direnv",
"jnoortheen.nix-ide",
"jnoortheen.nix-ide"
]
}
6 changes: 2 additions & 4 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@
"files.eol": "\n",

"files.exclude": {
".direnv": true,
".idea": true
".direnv": true
},

"files.readonlyInclude": {
Expand All @@ -16,7 +15,6 @@

"search.exclude": {
".direnv": true,
".idea": true,
"LICENSE*": true,
"flake.lock": true,
"Cargo.lock": true
Expand Down Expand Up @@ -64,5 +62,5 @@

"[nix]": {
"editor.defaultFormatter": "jnoortheen.nix-ide"
},
}
}
55 changes: 55 additions & 0 deletions .zed/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
{
"auto_install_extensions": {
"nix": true,
"toml": true
},

"remove_trailing_whitespace_on_save": true,
"ensure_final_newline_on_save": true,

"file_scan_exclusions": ["**/.git", "**/.direnv"],

"languages": {
"Rust": {
"language_servers": ["rust-analyzer"],
"format_on_save": "on",
"formatter": "language_server"
},

"Nix": {
"language_servers": ["nixd"],
"format_on_save": "on",
"formatter": "language_server"
}
},

"lsp": {
"rust-analyzer": {
"binary": {
"path": "rust-analyzer"
},

"initialization_options": {
"cargo": {
"features": "all"
},
"check": {
"command": "clippy"
},
"checkOnSave": true
}
},

"nixd": {
"binary": {
"path": "nixd"
},

"initialization_options": {
"formatting": {
"command": ["nixfmt", "--width=120"]
}
}
}
}
}

0 comments on commit c55c7fe

Please sign in to comment.