lantiq: replace backticks by $(...) and remove useless echo
authorAdrian Schmutzler <freifunk@adrianschmutzler.de>
Wed, 24 Jul 2019 22:47:13 +0000 (00:47 +0200)
committerChristian Lamparter <chunkeey@gmail.com>
Sat, 28 Sep 2019 22:46:13 +0000 (00:46 +0200)
This replaces deprecated backticks by more versatile $(...) syntax.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
[decapitalized patch subject at submitter's request]
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
target/linux/lantiq/base-files/etc/hotplug.d/dsl/pppoa.sh
target/linux/lantiq/base-files/lib/functions/lantiq_dsl.sh

index b9a3313c8361684c105d39995d876ff49a77ec56..4506737672f2456fe1b1208ad321f1e7439e90d6 100755 (executable)
@@ -8,7 +8,7 @@
 include /lib/network
 scan_interfaces
 
-interfaces=`ubus list network.interface.\* | cut -d"." -f3`
+interfaces=$(ubus list network.interface.\* | cut -d"." -f3)
 for ifc in $interfaces; do
 
        json_load "$(ifstatus $ifc)"
index 698d481140bfebd8053bb273c0730c511edcc693..cbdec1279cfde6de6abd610bd7953f7a11c4c8c8 100755 (executable)
@@ -290,8 +290,8 @@ xtse() {
                annex_s="$annex_s M,"
        fi
 
-       annex_s=`echo ${annex_s:1}`
-       annex_s=`echo ${annex_s%?}`
+       annex_s=${annex_s:1}
+       annex_s=${annex_s%?}
 
        # Evaluate Line Mode (according to G.997.1, 7.3.1.1.1)
 
@@ -346,8 +346,8 @@ xtse() {
                line_mode_s="$line_mode_s G.993.1 (VDSL),"
        fi
 
-       line_mode_s=`echo ${line_mode_s:1}`
-       line_mode_s=`echo ${line_mode_s%?}`
+       line_mode_s=${line_mode_s:1}
+       line_mode_s=${line_mode_s%?}
 
        xtse_s="${xtse1}, ${xtse2}, ${xtse3}, ${xtse4}, ${xtse5}, ${xtse6}, ${xtse7}, ${xtse8}"