[librsvg: 1/5] Make use of sudo optional in the gitlab CI rules




commit 96da82f4a44c74cb5e149bf6dd2f9053b27a0c6f
Author: Sven Neumann <sven svenfoo org>
Date:   Mon Sep 7 22:14:57 2020 +0200

    Make use of sudo optional in the gitlab CI rules
    
    The Fedora image seems to need sudo while the debian images do not
    provide it at all.

 .gitlab-ci.yml | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)
---
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index f814cae6..e0fc6d6b 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -39,9 +39,10 @@ stages:
     - rustc --version && cargo --version
     - mkdir -p _build
     - cd _build
-    - sudo ../autogen.sh --enable-gtk-doc --enable-vala
-    - sudo make
-    - sudo make check
+    - sudo=$(command -v sudo) || sudo=""
+    - $sudo ../autogen.sh --enable-gtk-doc --enable-vala
+    - $sudo make
+    - $sudo make check
 
   artifacts:
     when: 'always'


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