Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- tail -3f logfile.log | grep "action.*add" | sed -u -e "s/^/'/" -e "s/$/'/" | xargs -L 1 -P 5 bash testscript.sh
- tail -3f logfile.log | grep "action.*add"
- tail -3f /var/tmp/rabbitmq-tracing/logfile.log | grep "action.*add" | grep add
- tail -f file.txt | grep something | grep something | grep something
- {"twNotif": {"originator": "api", "chain": "test", "txId": "08640-0050568a5514", "version": "1.0", "msgType": "api", "twData": {"api": {"hostId": "007bdcc5", "user": "test", "cmdTxt": "100599"}}, "action": "add", "store": "test", "msgTime": 1467280648.971042}}
- tail -3f logfile.log | grep --line-buffered "action.*add" | sed -u -e "s/^/'/" -e "s/$/'/" | xargs -L 1 -P 5 bash testscript.sh
- ... | stdbuf -oL grep ... | ...
- tail -3f logfile.log | stdbuf -oL grep "action.*add" | sed -u -e "s/^/'/" -e "s/$/'/" | xargs -L 1 -P 5 bash testscript.sh
- jq -c 'select(.twNotif.action == "add")' file.txt |
- xargs -d'n' -r -L 1 -P 5 ./testscript.sh
- jq 'select(.twNotif.action == "add") | .twNotif.action' file.txt |
- sed -e 's/"//g' |
- xargs -d'n' -r -L 1 -P 5 ./testscript.sh
- jsonpipe < file.txt |
- awk '$1 == "/twNotif/action" {gsub(/"/,""); print $2}' |
- xargs -d'n' -r -L 1 -P 5 ./testscript.sh
- $ jsonpipe < file.txt
- / {}
- /twNotif {}
- /twNotif/originator "api"
- /twNotif/chain "test"
- /twNotif/txId "08640-0050568a5514"
- /twNotif/version "1.0"
- /twNotif/msgType "api"
- /twNotif/twData {}
- /twNotif/twData/api {}
- /twNotif/twData/api/hostId "007bdcc5"
- /twNotif/twData/api/user "test"
- /twNotif/twData/api/cmdTxt "100599"
- /twNotif/action "add"
- /twNotif/store "test"
- /twNotif/msgTime 1467280648.971042
- $ jsonpipe <file.txt | awk '{gsub(///,"."); print $1}'
- .
- .twNotif
- .twNotif.originator
- .twNotif.chain
- .twNotif.txId
- .twNotif.version
- .twNotif.msgType
- .twNotif.twData
- .twNotif.twData.api
- .twNotif.twData.api.hostId
- .twNotif.twData.api.user
- .twNotif.twData.api.cmdTxt
- .twNotif.action
- .twNotif.store
- .twNotif.msgTime
Add Comment
Please, Sign In to add comment