Skip to content

Instantly share code, notes, and snippets.

@thelazier
Last active March 3, 2017 11:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save thelazier/16e37e9a477c053d03c3d9261716cbb9 to your computer and use it in GitHub Desktop.
Save thelazier/16e37e9a477c053d03c3d9261716cbb9 to your computer and use it in GitHub Desktop.
Command on Linux to get current payment queue of masternode on Dash 12.1 network.
#!/usr/bin/env bash
MNADDR=$1
dash-cli masternodelist full | grep " ENABLED" | sed -e 's/[}|{]//' -e 's/"//g' -e 's/,//g' -e 's/^ *//g'| grep -v ^$ |tr -s ' '|awk '"echo `date +%s`-\(`dash-cli masternode count enabled`\*2.6\*60\)|bc"|getline minsigtime;($8!=0||$6>minsigtime)'| sort -n -k 8 |grep -n $MNADDR |sed -e 's/:/ /g'|cut -d ' ' -f 1,6 |awk '{"dash-cli masternode count enabled"|getline mncount; print $2" "$1"/"mncount}'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment