about summary refs log tree commit diff
path: root/modules/common
diff options
context:
space:
mode:
authorAzat Bahawi <azat@bahawi.net>2023-10-13 20:39:39 +0300
committerAzat Bahawi <azat@bahawi.net>2023-10-13 20:39:39 +0300
commit8207b0e249513feffd163d4228de685530fc665b (patch)
treec3b9e26b0b4f49873b2fc70bfc7f3b4a8a65f8bb /modules/common
parent2023-09-30 (diff)
2023-10-13
Diffstat (limited to '')
-rw-r--r--modules/common/common/home-manager.nix4
-rw-r--r--modules/common/emacs/default.nix19
-rw-r--r--modules/common/emacs/doom/config.el3
-rw-r--r--modules/common/profiles/dev/editorconfig.ini4
-rw-r--r--modules/common/vscode.nix2
5 files changed, 15 insertions, 17 deletions
diff --git a/modules/common/common/home-manager.nix b/modules/common/common/home-manager.nix
index 44b0eaa..97d7286 100644
--- a/modules/common/common/home-manager.nix
+++ b/modules/common/common/home-manager.nix
@@ -11,8 +11,8 @@ with lib; {
 
   hm = {
     news.display = "silent";
-    # NOTE Inheriting directly from `system.stateVersion` does not work on MacOS for
-    # some reason.
+    # NOTE Inheriting directly from `system.stateVersion` does not work with
+    # nix-darwin for some reason.
     home.stateVersion = with builtins;
       head (split "\n" (readFile "${inputs.nixpkgs}/.version"));
   };
diff --git a/modules/common/emacs/default.nix b/modules/common/emacs/default.nix
index a21b5ab..dfc657c 100644
--- a/modules/common/emacs/default.nix
+++ b/modules/common/emacs/default.nix
@@ -88,6 +88,11 @@ in {
                     gore # :lang go
                     gotools # :lang go
                     graphviz # :lang (org +roam2) :lang plantuml
+                    haskellPackages.cabal-fmt # :lang haskell :editor format
+                    haskellPackages.cabal-install # :lang haskell
+                    haskellPackages.haskell-language-server # :lang (haskell +lsp)
+                    haskellPackages.hoogle # :lang haskell
+                    haskellPackages.ormolu # :lang haskell :editor format
                     html-tidy # :lang web
                     jre # :lang plantuml
                     libtool # :term vterm
@@ -124,19 +129,7 @@ in {
                     if (this.system != "aarch64-darwin")
                     then [gdb] # :tools debugger
                     else [lldb] # :tools debugger
-                  )
-                  ++ optionals (!pkgs.stdenv.isDarwin)
-                  [
-                    # NOTE Haskell is pretty much broken every couple of days on
-                    # MacOS and I usually don't write anything in Haskell while
-                    # I'm on my work laptop, so... ShellCheck seems to be working,
-                    # though.
-                    haskellPackages.ormolu # :lang haskell :editor format
-                    haskellPackages.haskell-language-server # :lang (haskell +lsp)
-                    haskellPackages.cabal-fmt # :lang haskell :editor format
-                    haskellPackages.cabal-install # :lang haskell
-                    haskellPackages.hoogle # :lang haskell
-                  ];
+                  );
               in ''
                 ;; This will integrate packages which are required by various
                 ;; modules without polluting the user's profile.
diff --git a/modules/common/emacs/doom/config.el b/modules/common/emacs/doom/config.el
index 015954b..0000679 100644
--- a/modules/common/emacs/doom/config.el
+++ b/modules/common/emacs/doom/config.el
@@ -70,7 +70,8 @@
 ;;; Elisp
 ;;
 
-(pushnew! flycheck-disabled-checkers 'emacs-lisp-checkdoc)
+(after! flycheck
+  (pushnew! flycheck-disabled-checkers 'emacs-lisp-checkdoc))
 
 ;;
 ;;; Haskell
diff --git a/modules/common/profiles/dev/editorconfig.ini b/modules/common/profiles/dev/editorconfig.ini
index 17b0317..098229f 100644
--- a/modules/common/profiles/dev/editorconfig.ini
+++ b/modules/common/profiles/dev/editorconfig.ini
@@ -62,6 +62,10 @@ max_line_length = 72
 indent_size = 4
 indent_style = tab
 
+[*.{tf,hcl}]
+indent_size = 2
+indent_style = space
+
 [configure.ac]
 indent_size = 4
 indent_style = tab
diff --git a/modules/common/vscode.nix b/modules/common/vscode.nix
index ab55acc..3ae9800 100644
--- a/modules/common/vscode.nix
+++ b/modules/common/vscode.nix
@@ -168,7 +168,7 @@ in {
 
         terraform = {
           languageServer.path = "${pkgs.terraform-ls}/bin/terraform-ls";
-          languageServer.terraform.path = "${pkgs.terraform}/bin/terraform";
+          languageServer.terraform.path = "${pkgs.opentofu}/bin/tofu";
         };
 
         haskell = {

Consider giving Nix/NixOS a try! <3