Skip to content

Instantly share code, notes, and snippets.

View idan's full-sized avatar
💫
Prototypin'

Idan Gazit idan

💫
Prototypin'
View GitHub Profile
from appscript import *
import csv
reader = csv.reader(open('songlist.csv', 'rb'))
itunes = app('iTunes')
playlist = itunes.user_playlists['A Playlist']
for row in reader:
name, artist, album = row
print ("Copying %s by %s [%s}" % (name, artist, album))
Senator Schumer,
I am one of your constituents, and I'm writing you to express my extreme
disapproval of the COICA bill you recently voted for in the Senate Judiciary
committee.
This bill is harmful (and even offensive). It frightens me both as a citizen
and a web developer.
As a human being, it irks me to see the US attempting to regulate access to

There's been a recent explosion in git guis on the mac. I still keep coming back to GitX, specifically BrotherBard's fork:

Recently there have been a lot of new contenders:

  • Tower - pretty, nice inline diff viewer, seems like it might be more n00b-oriented, free while in beta.
  • GitBox - minimalistic. Also expensive.
  • SmartGit - commercial, expensive
<!doctype html>
<html>
<head>
<!-- All JavaScript at the bottom, except for Modernizr which enables HTML5 elements & feature detects -->
<script src="js/modernizr-1.6.min.js"></script>
<!--
Typekit needs to happen inside the HEAD, but below CSS, else we get the FOUT
http://www.stevesouders.com/blog/2009/10/13/font-face-and-performance/
-->
{% block typekit %}
JacobKM: Intro
RKM: Logging
Andrew Godwin: CBVs
? Paul ?: Testing improvements
jezdez: Static files
carljm: ON DELETE
gaynor: doctest removal
Andrewgodwin: something funny
ericholscher: deployment
ubernostrum: python 3
<article class="blogpost">
<header>
<h1>Title</h1>
<h2>Subtitle</h2>
</header>
<p> ... body paras ... </p>
<section class="comment">
<article>
<header>
<h1>Commenter Name</h1>
<a href="#ahuva">Jump to Ahuvah</a>
<!-- ... lots of content goes here ... -->
<h3 id="ahuvah">Ahuvah Berger</h3>
<p>... is awesome and full of win.</p>
@idan
idan / gist:793789
Created January 24, 2011 19:34
Google Docs Companywide Sharing

Sharing the document with "People at <my domain> can find and view" permission:

  • will make it possible for users to search for the document in Google Docs If the user knows the name or part of the name of the document, he can enter it in the Search field at the top of the Google Docs view and click on 'Search <my domain> Docs', If the user doesn't know the name, he can click on 'Show search options' to find other ways to find the document.
  • will add the document to users' Docs view once opened (under 'All Items' and 'Opened by me')
  • to avoid users' Google Docs view to be overflown by files they do not need, the file created by another user will not appear in the Google Docs view until searched and opened.

If you would like the document to appear in the user's Google Docs view without the user having to search for it first, you will need to share the document with him on an individual basis or with a group he is part of.

A quick way to do so is to add the document to a folder shared with the user. For mo

EXAM_STATES = {
'pending': 000,
'in progress': 100,
'complete': 200,
'abandoned': 300,
'tampered': 400,
}
EXAM_STATES_CHOICES = tuple(sorted(
[(v,k.title()) for k,v in EXAM_STATES.iteritems()],
Hey folks,
Though the hour's getting late
with tempers growing quite irate
your patience growing thin and weary
as you issue forth a query:
Where is Django Advent?
Though we struggle, work and try
sometimes authors don't comply