Skip to content

Instantly share code, notes, and snippets.

@hauleth
hauleth / install.sh
Last active August 29, 2015 14:00
Developer machine installation script
#!/bin/bash
# Add repositories
sudo add-apt-repository -y "deb http://repository.spotify.com stable non-free"
sudo add-apt-repository -y ppa:webupd8team/java
sudo add-apt-repository -y ppa:fish-shell/nightly-master
echo "deb http://downloads.hipchat.com/linux/apt stable main" | sudo tee \
/etc/apt/sources.list.d/atlassian-hipchat.list
sudo add-apt-repository -y ppa:linrunner/tlp
sudo apt-add-repository -y ppa:pipelight/stable
anonymous
anonymous / hyperscala_generated.scala
Created September 25, 2014 10:09
hyperscala generated
new tag.HTML {
contents += new tag.Head
contents += new tag.Body {
contents += new tag.Div {
contents += "Hello World"
}
}
}
@jeantil
jeantil / .Xdefault
Created August 13, 2010 16:52
cygwin config on windows with rxvt native
! rxvt-cygwin-native .Xdefault with sane colors
#ifdef COLOR
*customization: -color
#endif
! GVim colors, etc
!! GTK versions of gvim will not use all these.
Vim*useSchemes: all
Vim*sgiMode: true
@Khedi
Khedi / FinalSevens
Created June 3, 2011 19:16
Python Tetris-like numbers game using pygame
#Final Sevens
#6/5/2011
#Blocks already in curTiles that fall down don't trigger the scoring.
#Of the spawning blocks, 3 is overused. Maybe add in 4's and 5's
import pygame, sys, random, time
from pygame.locals import *
pygame.init()
gameClock = pygame.time.Clock()
package org.behrang.deliciouscleaner
@Grab(group = "net.sf.delicious-java", module = "delicious", version = "1.14")
import del.icio.us.Delicious
def d = new Delicious("username", "password")
def posts = d.allPosts
posts.eachWithIndex { p, i ->
println (i+1) + "/" + posts.size()
@chbaranowski
chbaranowski / GoogleDemoTest.java
Created June 5, 2011 14:49
Sikuli JUnit Demo Test
import org.junit.Test;
import org.sikuli.script.App;
import org.sikuli.script.Screen;
public class GoogleDemoTest {
@Test
public void testGoogleSearch() throws Exception {
Screen screen = new Screen();
App app = new App("Firefox 4.app");
@atomicules
atomicules / Smile.coffee
Last active September 26, 2015 06:27
Coffeescript source code for a bookmarklet to generate QIF files for SMILE bank.
#Bookmarklet to generate QIF for Recent Item and Previous Statement pages on SMILE.co.uk bank
#Will (try to) open a new popup window where you will have to either:
#a) Copy text from and paste to text editor (Chrome)
#b) Save the page as a text file (Firefox)
#
#Written in Coffescript, but just use http://javascriptcompressor.com/ to compress the
#compiled javascript so you have a bookmarklet.
data = document.getElementsByClassName("summaryTable")[0].children[1].children
<!DOCTYPE html>
<html>
<head>
<title>WebSocket test</title>
</head>
<body>
<script src="http://localhost:8080/socket.io/socket.io.js"></script>
<script>
var server = 'smtp.example.com',
port = 587,
@trygvis
trygvis / sbt
Created December 1, 2011 14:37
My SBT wrapper scripts
#!/bin/sh
if [ -z "$SBT_VERSION" ]
then
SBT_VERSION=0.7.7
fi
JAR=$HOME/.sbt/sbt-launch-$SBT_VERSION.jar
mkdir -p $HOME/.sbt
@kengonakajima
kengonakajima / moai_3d_simple_bench.lua
Created January 8, 2012 00:25
moai 3D simple benchmark from samples/test/cube-3d/main.lua
--[[---
Simple 3D benchmark based on samples/test/cube-3d.
- Video: http://www.youtube.com/watch?v=Fn54jJYw5y8&list=UUtHX3tIuYEScozlr4GqfF1Q
- Machine: macbook pro 2.53GHz i5, NVIDIA GeForce GT 330M 256 MB
- Benchmark spec
- num of props: 150
- cube per prop : 8x8x8 = 512
- total num of triangles: 12 x 512 x 150 = 921K
- frame rate: 60fps