Skip to content

Instantly share code, notes, and snippets.

@dbiesecke
Created March 28, 2024 13:49
Show Gist options
  • Save dbiesecke/f5aee99d011aec62e8bb8e57bf83f479 to your computer and use it in GitHub Desktop.
Save dbiesecke/f5aee99d011aec62e8bb8e57bf83f479 to your computer and use it in GitHub Desktop.
Check usenet accounts for upload
#/bin/bash
#
#
# % ~/bin/check_usenet_upload "xsnews.nl xsn PASSS"
#
#
#
# 'https://github.com/mbruel/ngPost/releases/download/v4.14/ngPost_v4.14_cmd-x86_64.AppImage'
#
# curl 'https://github.com/mbruel/ngPost/releases/download/v4.14/ngPost_v4.14_cmd-x86_64.AppImage' > ~/bin/ngPost && chmod +x ~/bin/ngPost
NG="ngPost"
MYTEST="$1"
MYCMD=$( echo "$MYTEST" | awk '{print "ngPost -t 1 -h news."$1" -P 443 -s -u "$2" -p \""$3"\" -n 30 -f [email protected] -g alt.binaries.test -a 64000 -i /tmp/folderToPost -o test.nzb"}' )
#echo $MYCMD
mkdir -p /tmp/folderToPost 2>/dev/null
echo 1111111 > /tmp/folderToPost/testing
export NO_RESUME_AUTO=1
MYRES=$($MYCMD)
( $MYCMD > /dev/null && echo "SUCCES $MYTEST" )
rm -fR "/tmp/folderToPost"
test -f test.nzb && rm test.nzb
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment