Skip to content

Instantly share code, notes, and snippets.

View jcelliott's full-sized avatar

Joshua C Elliott jcelliott

View GitHub Profile
package main
import "fmt"
type Quacker interface {
Quack()
}
type Duck struct{}
package main
import "fmt"
type Vehicle struct{}
func (v Vehicle) Move() {
fmt.Println("vehicle moving")
}
package main
import "fmt"
type Vehicle struct{}
func (v Vehicle) Move() {
fmt.Println("vehicle moving")
}
#!/usr/bin/env bash
# ~/bin/home
# toggles source control on my home directory
# idea from [http://rhodesmill.org/brandon/2012/home-directory-vc/]
# colorized output
function cinfo() {
echo -e "\x1b[32m$1\x1b[0m" # green
}
function cwarn() {
@jcelliott
jcelliott / gist:4119659
Created November 20, 2012 18:01
ValidationError
Environment:
Request Method: GET
Request URL: http://127.0.0.1:8000/list/item/add/
Django Version: 1.4.2
Python Version: 2.6.5
Installed Applications:
('django.contrib.auth',