Guest User

mail

a guest
Aug 9th, 2017
68
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.33 KB | None | 0 0
  1. USER=
  2. PASS=
  3.  
  4. COUNT=`curl -su $USER:$PASS https://mail.google.com/mail/feed/atom || echo "<fullcount>unknown number of</fullcount>"`
  5. COUNT=`echo "$COUNT" | grep -oPm1 "(?<=<fullcount>)[^<]+" `
  6. echo $COUNT
  7. if [ "$COUNT" != "0" ]; then
  8. if [ "$COUNT" = "1" ];then
  9. WORD="mail";
  10. else
  11. WORD="mails";
  12. fi
  13. fi
Add Comment
Please, Sign In to add comment