Skip to content

Instantly share code, notes, and snippets.

require "spec_helper"
describe ExampleController do
context "GET #index" do
let(:resources) { FactoryGirl.create_list(:resource) }
before do
get :index
end
# Ring the bell if any background window rang a bell
set -g bell-action any
# Default termtype. If the rcfile sets $TERM, that overrides this value.
set -g default-terminal screen-256color
# Keep your finger on ctrl, or don't
bind-key ^D detach-client
# Create splits and vertical splits
@rocknrollMarc
rocknrollMarc / deploy.zsh
Created March 17, 2015 12:50
github-pages-deployscript
#!/bin/zsh
echo -e "\033[0;32mDeploying updates to GitHub...\033[0m"
# Building the project.
hugo
# Add changes to git.
git add -A
@rocknrollMarc
rocknrollMarc / main.go
Last active August 29, 2015 14:16
Go webapp with gorilla and Negroni
package main
import (
"fmt"
"log"
"net/http"
"github.com/codegangsta/negroni"
"github.com/gorilla/mux"
"github.com/russross/blackfriday"
#### ####
#### ####
#### ####
#### ####
###########################################################################################
###########################################################################################
###########################################################################################
###########################################################################################
##########
package main
import (
"encoding/json"
"fmt"
"time"
)
//<start id="refactoredticket">
type TicketDisposition int
.PHONY: build doc fmt lint run test vendor_clean vendor_get vendor_update vet
# Prepend our _vendor directory to the system GOPATH
# so that import path resolution will prioritize
# our third party snapshots.
GOPATH := ${PWD}/_vendor:${GOPATH}
export GOPATH
default: build
package main
import (
"archive/zip"
"fmt"
"io"
"log"
"os"
)
// Copyright 2015, rocknrollmarc. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
// balancer.go [created: Thu, 19 Feb 2015]
package main
import (
"flag"
package main
import (
"net/http"
"github.com/russross/blackfriday"
)
func main() {
http.HandleFunc("/markdown", GenerateMarkdown)