summary refs log tree commit diff
path: root/pkgs/development/tools/parsing/tree-sitter/grammar.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/development/tools/parsing/tree-sitter/grammar.nix')
-rw-r--r--pkgs/development/tools/parsing/tree-sitter/grammar.nix6
1 files changed, 3 insertions, 3 deletions
diff --git a/pkgs/development/tools/parsing/tree-sitter/grammar.nix b/pkgs/development/tools/parsing/tree-sitter/grammar.nix
index c2c3ce4a896..ce46e3623ba 100644
--- a/pkgs/development/tools/parsing/tree-sitter/grammar.nix
+++ b/pkgs/development/tools/parsing/tree-sitter/grammar.nix
@@ -28,10 +28,10 @@ stdenv.mkDerivation ({
 
   stripDebugList = [ "parser" ];
 
-  configurePhase = lib.optionalString generate ''
-    tree-sitter generate
-  '' + lib.optionalString (location != null) ''
+  configurePhase = lib.optionalString (location != null) ''
     cd ${location}
+  '' + lib.optionalString generate ''
+    tree-sitter generate
   '';
 
   # When both scanner.{c,cc} exist, we should not link both since they may be the same but in