This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#install imagemagick first | |
animate myimg.gif | |
#The window is by default borderless (you do have to be in an X GUI). You can resize: | |
animate -resize 1920x1080 myimg.gif | |
#or convert | |
convert myimg.gif -coalesce myimg2.gif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# keeps stream active if ever fails | |
#install livestreamer first | |
while true | |
do | |
livestreamer website.stream best -np 'omxplayer -o hdmi' | |
done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Raspberry pi video player loop | |
# Ross Jeffcoat 2012 | |
# requires omxplayer installed | |
#clears the screen | |
clear | |
#mount usb thumb drive - make sure /media/usbstick/ is already created in root | |
mount -t vfat -o rw /dev/sda1 /media/usbstick/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from datetime import datetime | |
import urllib2 | |
import urllib | |
import json | |
import os | |
#wait for network | |
time.sleep(45) | |
def ajaxRequest(url=None): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# from reddit http://www.reddit.com/r/linuxmint/comments/1yhsl1/hot_corners_showing_desktop/cfl5vsu | |
wmctrl -m | grep -Eo "^Window manager's \"showing the desktop\" mode: ([OFN]{2,3})$" | grep -oE "ON" > /dev/null | |
if [ $? -eq 0 ]; then | |
echo $? | |
wmctrl -k off; | |
else | |
echo $? | |
wmctrl -k on; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
try | |
tell application "Finder" | |
set currentPath to (POSIX path of (target of front window as alias)) | |
#define delimeter and make shorter path for subject | |
set subjectPATH to currentPath | |
set AppleScript's text item delimiters to "/" | |
set stringPath to subjectPATH as string | |
set shortPath to text items 6 thru end of stringPath | |
set the_Subject to "Link to files: " & shortPath |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$(document).ready(function() { | |
/* | |
/* Load json on click | |
/*/ | |
$('#element').on('click', function(e){ | |
$.ajax({ | |
type: 'GET', | |
url: 'api/myjsonlink.json', | |
dataType: 'json', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
javascript:window.open('http://compose.mail.yahoo.com?subject=FWD: '+encodeURIComponent(escape(document.title))+'&BODY='+encodeURIComponent(escape(document.title))+' \n '+encodeURIComponent(window.location.href),'newEmailYahoo','status=no,directories=no,location=no,resizable=yes,menubar=no,width=800,height=600,toolbar=no'); |