Commit 67274b24 authored by Matteo Quintiliani's avatar Matteo Quintiliani

Renamed and improved nmxptool_filelist.sh


git-svn-id: file:///home/quintiliani/svncopy/nmxptool/trunk@1139 3cd66e75-5955-46cb-a940-c26e5fc5497d
parent 63941781
#!/bin/sh
. `dirname $0`/nmxp_sds.conf
# Syntax
SYNTAX="$0 <hostname> <'naqs'|'data'> [regexp_channel]"
HOSTNAME=$1
NAQSORDATA=$2
REGEXP=$3
if [ -z "${HOSTNAME}" ]; then
echo ""
echo "Syntax: ${SYNTAX}"
echo ""
exit
fi
if [ "${NAQSORDATA}" != "naqs" ] && [ ${NAQSORDATA} != "data" ]; then
echo ""
echo "Syntax: ${SYNTAX}"
echo ""
exit
fi
if [ "${NAQSORDATA}" == "naqs" ]; then
NMXP_EXTRAOPTS="-L"
fi
if [ ${NAQSORDATA} == "data" ]; then
NMXP_EXTRAOPTS="-l"
fi
$NMXPTOOL -H $HOSTNAME ${NMXP_EXTRAOPTS} | grep -E "${REGEXP}" | sed -e "s/[ ][ ]*/ /g" | cut -d' ' -f 3
#!/bin/sh
# Syntax
SYNTAX="$0 <hostname> [regexp_channel]"
HOSTNAME=$1
REGEXP=$2
if [ -z "${HOSTNAME}" ]; then
echo ""
echo "Syntax: ${SYNTAX}"
echo ""
exit
fi
../src/nmxptool -H $HOSTNAME -L | grep -E "${REGEXP}" | sed -e "s/^.* //" -e "s/[ ][ ]*$//"
# ../src/nmxptool -H $HOSTNAME -L | grep HZ | sed -e "s/^.* //" -e "s/HZ/H?/g"
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment