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
package main | |
/* | |
#cgo CFLAGS: -x objective-c | |
#cgo LDFLAGS: -framework Cocoa | |
#import <Cocoa/Cocoa.h> | |
#import <Foundation/Foundation.h> | |
#import <IOBluetooth/IOBluetooth.h> | |
void call_objc_example(void) { |
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
package main | |
/* | |
#cgo CFLAGS: -x objective-c | |
#cgo LDFLAGS: -framework Cocoa | |
#import <Cocoa/Cocoa.h> | |
void call_objc_example(void) { | |
NSLog(@"from objective-c"); | |
} |
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
cd /tmp | |
if [[ "`uname`" == 'Linux' ]]; then | |
curl -so go.tar.gz http://go.googlecode.com/files/go1.1.1.linux-amd64.tar.gz | |
else | |
curl -so go.tar.gz http://go.googlecode.com/files/go1.1.1.darwin-amd64.tar.gz | |
fi | |
tar xf go.tar.gz | |
export GOPATH=/tmp | |
export GOROOT=/tmp/go |
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
// parses arguments into a time duration and prints the number of seconds it represents | |
package main | |
import ( | |
"fmt" | |
"os" | |
"strings" | |
"time" | |
) |
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/sh | |
set -e | |
MTIME=$(date -r $1 +%s) | |
EXPDELTA=$(cat $1) | |
NOW=$(date +%s) | |
expr $MTIME + $EXPDELTA - $NOW \< 0 |
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
{{define "extra_head"}}{{end}} | |
{{define "nav"}} | |
<li><a href="/">Home</a></li> | |
<li class="active"><a href="#">About</a></li> | |
<li><a href="/contact">Contact</a></li> | |
<li><a href="/privacy">Privacy</a></li> | |
{{end}} | |
{{define "content"}} | |
<div class="row-fluid marketing"> |
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
☭ ~ $ revel new sweet_app | |
☭ ~ $ cd sweet_app/ | |
☭ ~/sweet_app $ git init | |
☭ ~/sweet_app (master)$ cat > .godir | |
sweet_app | |
^C | |
☭ ~/sweet_app (master)$ git add .godir * | |
☭ ~/sweet_app (master)$ git ci -m"Initial" | |
☭ ~/sweet_app (master)$ heroku create --buildpack https://github.com/robfig/heroku-buildpack-go-revel.git | |
☭ ~/sweet_app (master)$ git push heroku |
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
#views.py | |
def link_accounts(request): | |
if request.method == 'POST': # If the form has been submitted... | |
#De-listify the stupid freakin' post request11!!11 | |
form = LinkForm(initial=init) # A form bound to the POST data | |
print "HEREEEEEE" | |
if form.is_valid(): # All valid |
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
<project-report> | |
<project-name>lab5</project-name> **Required | |
<upload-date>NONE</upload-date> **Required | |
<upload-updated>NONE</upload-updated> **Required | |
<due-date>2011-10-20 00:00:00</due-date> **Required | |
<section-name>W</section-name> **Required | |
<grader-name>GRADER_Last</grader-name> **Required | |
<student-info> **Required | |
<student-name>Barish,David</student-name> **Required | |
<student-kuid>3450008</student-kuid> **Required |
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
Version = 5 | |
Booleans = {'caretLineVisible': True, 'preferFixed': True, 'useSelFore': True} | |
CommonStyles = {'attribute name': {'fore': 13236445}, | |
'attribute value': {'fore': 3100463}, | |
'bracebad': {'back': 6710886, 'bold': 1, 'fore': 13421823}, | |
'bracehighlight': {'bold': 1, 'fore': 16777215}, | |
'classes': {'fore': 8578762}, | |
'comments': {'fore': 10066329, 'italic': False}, |