Merge pull request #7 from dschaper/dschaper-regex-patch
Was looking at those lines earlier...
So simple take what's between the {}.
thanks for the improvement.
This commit is contained in:
commit
3abe17d674
1 changed files with 1 additions and 3 deletions
|
|
@ -32,10 +32,8 @@ SCRIPTDIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
|||
echo -e "\033[33m"
|
||||
echo "Adding the ADS-B Exchange feed to PiAware's configuration..."
|
||||
echo -e "\033[37m"
|
||||
MLATRESULTFORMAT=`sudo piaware-config -show | grep mlatResultsFormat`
|
||||
ORIGINALFORMAT=`sed 's/mlatResultsFormat //g' <<< $MLATRESULTFORMAT`
|
||||
ORIGINALFORMAT=`sudo piaware-config -show | sed -n 's/.*{\(.*\)}.*/\1/p'`
|
||||
CLEANFORMAT=`sed 's/ beast,connect,feed.adsbexchange.com:30005//g' <<< $ORIGINALFORMAT`
|
||||
CLEANFORMAT=`sed 's/[{}]//g' <<< $CLEANFORMAT`
|
||||
COMMAND=`sudo piaware-config -mlatResultsFormat "${CLEANFORMAT} beast,connect,feed.adsbexchange.com:30005"`
|
||||
$COMMAND
|
||||
sudo piaware-config -restart
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue