gnunet-svn
[Top][All Lists]
Advanced

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

[gnunet] branch master updated: fix some linting issues


From: gnunet
Subject: [gnunet] branch master updated: fix some linting issues
Date: Mon, 28 Dec 2020 23:47:35 +0100

This is an automated email from the git hooks/post-receive script.

grothoff pushed a commit to branch master
in repository gnunet.

The following commit(s) were added to refs/heads/master by this push:
     new 38b2445cb fix some linting issues
38b2445cb is described below

commit 38b2445cbe48df349438c50670cf194544897de6
Author: Christian Grothoff <christian@grothoff.org>
AuthorDate: Mon Dec 28 23:47:01 2020 +0100

    fix some linting issues
---
 doc/man/produce_html.sh.in                           |  2 +-
 src/gns/test_gnunet_gns.sh.in                        |  2 +-
 src/gns/test_proxy.sh                                |  8 ++++----
 src/reclaim/test_reclaim_consume.sh                  |  6 +++---
 src/reclaim/test_reclaim_issue.sh                    |  2 +-
 src/reclaim/test_reclaim_revoke.sh                   | 10 +++++-----
 src/scalarproduct/test_scalarproduct.sh              |  4 ++--
 src/scalarproduct/test_scalarproduct_negative.sh     |  4 ++--
 src/scalarproduct/test_scalarproduct_negativezero.sh |  4 ++--
 9 files changed, 21 insertions(+), 21 deletions(-)

diff --git a/doc/man/produce_html.sh.in b/doc/man/produce_html.sh.in
index d2bd768a8..8680c0106 100755
--- a/doc/man/produce_html.sh.in
+++ b/doc/man/produce_html.sh.in
@@ -1,4 +1,4 @@
-#!/bin/sh
+#!/bin/bash
 
 if test -e @PKGDATADIRECTORY@/existence.sh
 then
diff --git a/src/gns/test_gnunet_gns.sh.in b/src/gns/test_gnunet_gns.sh.in
index 8cdd062c7..8a96ff034 100755
--- a/src/gns/test_gnunet_gns.sh.in
+++ b/src/gns/test_gnunet_gns.sh.in
@@ -1,4 +1,4 @@
-#!/bin/sh
+#!/bin/bash
 # This file is in the public domain.
 # test -z being correct was a false assumption here.
 # I have no executable 'fooble', but this will
diff --git a/src/gns/test_proxy.sh b/src/gns/test_proxy.sh
index 7c17cd4c5..ee288413f 100755
--- a/src/gns/test_proxy.sh
+++ b/src/gns/test_proxy.sh
@@ -31,10 +31,10 @@ cat local.crt > /tmp/server_cacert.pem
 cat local.key >> /tmp/server_cacert.pem
 
 gnunet-identity -C test -c test_gns_proxy.conf
-gnunet-namestore -p -z test -a -n www -t A -V 127.0.0.1 -e never -c 
test_gns_proxy.conf
-gnunet-namestore -p -z test -a -n www -t LEHO -V "test.local" -e never -c 
test_gns_proxy.conf
-gnunet-namestore -p -z test -a -n www -t BOX -V "$OLDBOXVALUE" -e never -c 
test_gns_proxy.conf
-gnunet-namestore -p -z test -a -n www -t BOX -V "$BOXVALUE" -e never -c 
test_gns_proxy.conf
+gnunet-namestore -p -z "test" -a -n www -t A -V 127.0.0.1 -e never -c 
test_gns_proxy.conf
+gnunet-namestore -p -z "test" -a -n www -t LEHO -V "test.local" -e never -c 
test_gns_proxy.conf
+gnunet-namestore -p -z "test" -a -n www -t BOX -V "$OLDBOXVALUE" -e never -c 
test_gns_proxy.conf
+gnunet-namestore -p -z "test" -a -n www -t BOX -V "$BOXVALUE" -e never -c 
test_gns_proxy.conf
 
 gnunet-arm -i gns-proxy -c test_gns_proxy.conf
 
diff --git a/src/reclaim/test_reclaim_consume.sh 
b/src/reclaim/test_reclaim_consume.sh
index 55f6ff22c..9186d3cb1 100755
--- a/src/reclaim/test_reclaim_consume.sh
+++ b/src/reclaim/test_reclaim_consume.sh
@@ -6,7 +6,7 @@ if [ -z $LOCATION ]
 then
   LOCATION="gnunet-config"
 fi
-$LOCATION --version 1> /dev/null
+$LOCATION --version 1>/dev/null
 if test $? != 0
 then
        echo "GNUnet command line tools cannot be found, check environmental 
variables PATH and GNUNET_PREFIX"
@@ -20,7 +20,7 @@ rm -rf `gnunet-config -c test_reclaim.conf -s PATHS -o 
GNUNET_HOME -f`
 #  (3) PKEY3.user -> PKEY4
 
 
-which timeout &> /dev/null && DO_TIMEOUT="timeout 30"
+which timeout >/dev/null 2>&1 && DO_TIMEOUT="timeout 30"
 
 TEST_ATTR="test"
 gnunet-arm -s -c test_reclaim.conf
@@ -32,7 +32,7 @@ TEST_KEY=$(gnunet-identity -d -e testego -q -c 
test_reclaim.conf)
 gnunet-reclaim -e testego -a email -V john@doe.gnu -c test_reclaim.conf
 gnunet-reclaim -e testego -a name -V John -c test_reclaim.conf
 TICKET=$(gnunet-reclaim -e testego -i "email,name" -r $SUBJECT_KEY -c 
test_reclaim.conf | awk '{print $1}')
-gnunet-reclaim -e rpego -C $TICKET -c test_reclaim.conf > /dev/null 2>&1
+gnunet-reclaim -e rpego -C $TICKET -c test_reclaim.conf >/dev/null 2>&1
 
 if test $? != 0
 then
diff --git a/src/reclaim/test_reclaim_issue.sh 
b/src/reclaim/test_reclaim_issue.sh
index 7ab8a6980..cfddc9407 100755
--- a/src/reclaim/test_reclaim_issue.sh
+++ b/src/reclaim/test_reclaim_issue.sh
@@ -20,7 +20,7 @@ rm -rf `gnunet-config -c test_reclaim.conf -s PATHS -o 
GNUNET_HOME -f`
 #  (3) PKEY3.user -> PKEY4
 
 
-which timeout &> /dev/null && DO_TIMEOUT="timeout 30"
+which timeout >/dev/null 2>&1 && DO_TIMEOUT="timeout 30"
 
 TEST_ATTR="test"
 gnunet-arm -s -c test_reclaim.conf
diff --git a/src/reclaim/test_reclaim_revoke.sh 
b/src/reclaim/test_reclaim_revoke.sh
index ffbc7ef2b..da091a1ee 100755
--- a/src/reclaim/test_reclaim_revoke.sh
+++ b/src/reclaim/test_reclaim_revoke.sh
@@ -20,10 +20,10 @@ rm -rf `gnunet-config -c test_reclaim.conf -s PATHS -o 
GNUNET_HOME -f`
 #  (3) PKEY3.user -> PKEY4
 
 
-which timeout &> /dev/null && DO_TIMEOUT="timeout 30"
+which timeout >/dev/null 2&>1 && DO_TIMEOUT="timeout 30"
 
 TEST_ATTR="test"
-gnunet-arm -s -c test_reclaim.conf 2&>1 > /dev/null
+gnunet-arm -s -c test_reclaim.conf >/dev/null 2&>1
 gnunet-identity -C alice -c test_reclaim.conf
 gnunet-identity -C bob -c test_reclaim.conf
 gnunet-identity -C eve -c test_reclaim.conf
@@ -43,7 +43,7 @@ sleep 16
 echo "Consuming $TICKET"
 
 gnunet-reclaim -e eve -C $TICKET_EVE -c test_reclaim.conf
-if test $? == 0
+if test $? = 0
 then
   echo "Eve can still resolve attributes..."
   gnunet-arm -e -c test_reclaim.conf
@@ -51,10 +51,10 @@ then
 fi
 
 gnunet-arm -e -c test_reclaim.conf
-gnunet-arm -s -c test_reclaim.conf 2&>1 > /dev/null
+gnunet-arm -s -c test_reclaim.conf >/dev/null 2&>1
 
 gnunet-reclaim -e bob -C $TICKET_BOB -c test_reclaim.conf
-#gnunet-reclaim -e bob -C $TICKET_BOB -c test_reclaim.conf 2&>1 >/dev/null
+#gnunet-reclaim -e bob -C $TICKET_BOB -c test_reclaim.conf >/dev/null 2&>1
 if test $? != 0
 then
   echo "Bob cannot resolve attributes..."
diff --git a/src/scalarproduct/test_scalarproduct.sh 
b/src/scalarproduct/test_scalarproduct.sh
index c0401beb7..ed91cd5c4 100755
--- a/src/scalarproduct/test_scalarproduct.sh
+++ b/src/scalarproduct/test_scalarproduct.sh
@@ -25,7 +25,7 @@ echo "Waiting for peers to start..."
 sleep 5
 echo "Running test..."
 
-which timeout &> /dev/null && DO_TIMEOUT="timeout 15"
+which timeout >/dev/null 2>&1 && DO_TIMEOUT="timeout 15"
 
 # get bob's peer ID, necessary for alice
 PEERIDBOB=`${DO_TIMEOUT} gnunet-peerinfo -qs $CFGBOB`
@@ -38,7 +38,7 @@ RESULT=`${DO_TIMEOUT} gnunet-scalarproduct $CFGALICE 
$INPUTALICE -p $PEERIDBOB`
 # terminate the testbed
 kill $PID
 
-if [ "$RESULT" == "$EXPECTED" ]
+if [ "$RESULT" = "$EXPECTED" ]
 then
        echo "OK"
        exit 0
diff --git a/src/scalarproduct/test_scalarproduct_negative.sh 
b/src/scalarproduct/test_scalarproduct_negative.sh
index cbeb1b9fd..b08e4527f 100755
--- a/src/scalarproduct/test_scalarproduct_negative.sh
+++ b/src/scalarproduct/test_scalarproduct_negative.sh
@@ -11,7 +11,7 @@ PREFIX=/tmp/test-scalarproduct`date +%H%M%S`
 CFGALICE="-c $PREFIX/0/config"
 CFGBOB="-c $PREFIX/1/config"
 
-which timeout &> /dev/null && DO_TIMEOUT="timeout 15"
+which timeout >/dev/null 2>&1 && DO_TIMEOUT="timeout 15"
 
 # launch two peers in line topology non-interactively
 #
@@ -36,7 +36,7 @@ RESULT=`${DO_TIMEOUT} gnunet-scalarproduct $CFGALICE 
$INPUTALICE -p $PEERIDBOB`
 kill $PID
 
 EXPECTED="-0CCC"
-if [ "$RESULT" == "$EXPECTED" ]
+if [ "$RESULT" = "$EXPECTED" ]
 then
        echo "OK"
         exit 0
diff --git a/src/scalarproduct/test_scalarproduct_negativezero.sh 
b/src/scalarproduct/test_scalarproduct_negativezero.sh
index 1ab7157af..6f80b2ea2 100755
--- a/src/scalarproduct/test_scalarproduct_negativezero.sh
+++ b/src/scalarproduct/test_scalarproduct_negativezero.sh
@@ -22,7 +22,7 @@ PID=$!
 # sleep 1 is too short on most systems, 2 works on most, 5 seems to be safe
 sleep 5
 
-which timeout &> /dev/null && DO_TIMEOUT="timeout 15"
+which timeout >/dev/null 2>&1 && DO_TIMEOUT="timeout 15"
 
 # get bob's peer ID, necessary for alice
 PEERIDBOB=`${DO_TIMEOUT} gnunet-peerinfo -qs $CFGBOB`
@@ -36,7 +36,7 @@ RESULT=`${DO_TIMEOUT} gnunet-scalarproduct $CFGALICE 
$INPUTALICE -p $PEERIDBOB`
 kill $PID
 
 EXPECTED="00"
-if [ "$RESULT" == "$EXPECTED" ]
+if [ "$RESULT" = "$EXPECTED" ]
 then
        echo "OK"
         exit 0

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]