[gnome-builder] cargo: implement do_supports_language()



commit c8278b4887eed85daed1be82dbc27af47864e453
Author: Christian Hergert <chergert redhat com>
Date:   Mon Aug 2 14:08:19 2021 -0700

    cargo: implement do_supports_language()
    
    Just assume anything cargo is building Rust, because you'd have to be
    crazy to use it for anything else.

 src/plugins/cargo/cargo_plugin.py | 3 +++
 1 file changed, 3 insertions(+)
---
diff --git a/src/plugins/cargo/cargo_plugin.py b/src/plugins/cargo/cargo_plugin.py
index 4c228a783..e463881ca 100644
--- a/src/plugins/cargo/cargo_plugin.py
+++ b/src/plugins/cargo/cargo_plugin.py
@@ -55,6 +55,9 @@ class CargoBuildSystem(Ide.Object, Ide.BuildSystem):
     def do_get_priority(self):
         return -200
 
+    def do_supports_language(self, language):
+        return language in ('rust',)
+
 def locate_cargo_from_config(config):
     cargo = _CARGO
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]