Skip to content

Instantly share code, notes, and snippets.

View jozefcipa's full-sized avatar
🦕

Jozef Cipa jozefcipa

🦕
View GitHub Profile
@ellcom
ellcom / AppleScript.Spotify.PlayPause.scpt
Created August 2, 2014 17:02
Tell spotify to play/pause using AppleScript
using terms from application "Spotify"
if player state of application "Spotify" is paused then
tell application "Spotify" to play
else
tell application "Spotify" to pause
end if
end using terms from
@hSATAC
hSATAC / gist:5343225
Created April 9, 2013 05:38
Http Redirect in Golang
package main
import (
"log"
"net/http"
)
func redirect(w http.ResponseWriter, r *http.Request) {
http.Redirect(w, r, "http://www.google.com", 301)
{
"Object.getPrototypeOf": {
"prefix": "op",
"body": "Object.getPrototypeOf(${0})"
},
"Object.getOwnPropertyNames": {
"prefix": "opn",
"body": "Object.getOwnPropertyNames(${0})"
},
"setTimeout": {
#/bin/bash
DIR=$1
RED='\033[0;31m'
GREEN='\033[0;32m'
BLUE='\033[1;34m'
ORANGE='\033[1;33m'
NC='\033[0m' # No Color