Inspired by "Parsing CSS with Parsec".
Just quick notes and code that you can play with in REPL.
By @kachayev
Inspired by "Parsing CSS with Parsec".
Just quick notes and code that you can play with in REPL.
By @kachayev
# Gmail checker for Xmobar | |
# | |
# Install the ruby-gmail and mime gem to system | |
# Put the script under ~/path/to/gmail_checker.rb | |
# Make sure it is executable | |
require 'gmail' | |
gmail = Gmail.new('example@gmail.com', 'password') | |
mail_count = gmail.inbox.count(:unread) |