Skip to content

Instantly share code, notes, and snippets.

@gubi
gubi / fa-bounce.css
Last active Apr 1, 2022
Pulse animation for FontAwesome icons
View fa-bounce.css
.fa-bounce {
display: inline-block;
position: relative;
-moz-animation: bounce 1s infinite linear;
-o-animation: bounce 1s infinite linear;
-webkit-animation: bounce 1s infinite linear;
animation: bounce 1s infinite linear;
}
@-webkit-keyframes bounce {
@dzuelke
dzuelke / flagged_mails_to_thl.applescript
Created Jan 29, 2012
AppleScript to import flagged messages from Mail into The Hit List
View flagged_mails_to_thl.applescript
#!/usr/bin/osascript
on run
if not (application "Mail" is running and application "The Hit List" is running) then
return
end if
tell application "Mail"
repeat with _account in imap accounts
set _inbox to _account's mailbox "INBOX"
set _messages to (a reference to (every message of _inbox whose flagged status is true))
-- We must use this workaround, because the reference will self-update once we unflag a message, and that will get us just one of two flagged messages imported
@JosephPecoraro
JosephPecoraro / shell-execution.rb
Last active Apr 11, 2022
Shell Execution in Ruby
View shell-execution.rb
# Ways to execute a shell script in Ruby
# Example Script - Joseph Pecoraro
cmd = "echo 'hi'" # Sample string that can be used
# 1. Kernel#` - commonly called backticks - `cmd`
# This is like many other languages, including bash, PHP, and Perl
# Synchronous (blocking)
# Returns the output of the shell command
# Docs: http://ruby-doc.org/core/classes/Kernel.html#M001111