aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--home.nix1
-rw-r--r--home/editorconfig.nix24
2 files changed, 25 insertions, 0 deletions
diff --git a/home.nix b/home.nix
index 6e44c61..0238087 100644
--- a/home.nix
+++ b/home.nix
@@ -15,6 +15,7 @@
./home/ghostty.nix
./home/mime-apps.nix
./home/xdg-user-dirs.nix
+ ./home/editorconfig.nix
];
home = {
diff --git a/home/editorconfig.nix b/home/editorconfig.nix
new file mode 100644
index 0000000..5c4561c
--- /dev/null
+++ b/home/editorconfig.nix
@@ -0,0 +1,24 @@
+{
+ editorconfig = {
+ enable = true;
+
+ settings = {
+ "*" = {
+ charset = "utf-8";
+ end_of_line = "lf";
+ insert_final_newline = true;
+ indent_size = 2;
+ indent_style = "space";
+ trim_trailing_whitespace = true;
+ };
+
+ "*.md" = {
+ indent_size = 4;
+ };
+
+ "*.rs" = {
+ indent_size = 4;
+ };
+ };
+ };
+}