Skip to content

Instantly share code, notes, and snippets.

@camelpunch
camelpunch / gpg-ssh
Last active September 12, 2017 12:21
#!/bin/bash
set -eu
gpg --card-status > /dev/null
killall ssh-agent gpg-agent
unset GPG_AGENT_INFO SSH_AGENT_PID SSH_AUTH_SOCK
gpg-agent --daemon --enable-ssh-support
@camelpunch
camelpunch / Dockerfile
Last active March 14, 2017 13:57
Cross-compile Haskell
FROM debian:jessie
RUN apt-get update && apt-get install -yy \
curl \
build-essential
RUN curl -sSL https://get.haskellstack.org/ | sh
RUN stack setup
COPY ./ project
ENV LC_ALL=C.UTF-8
RUN cd project && stack install
touch -t $(git log -n1 --format=%cd --date=format:%Y%m%d%H%M.%S ../README.md) ../README.md
#import "ViewController.h"
@import RMQClient;
@interface ViewController ()
@end
@implementation ViewController
- (void)viewDidLoad {
amq-protocol$ ./bin/rspec -b spec
Running on 2.2.2
........................................................................................................................................................F.....................................................................................................................................................................................................................................................................
Failures:
1) AMQ::Protocol::Method.encode_body when the body fits perfectly in a single frame encodes a body into a single BodyFrame
Failure/Error: expect(body_frames.size).to eq(1)
expected: 1
0 info it worked if it ends with ok
1 verbose cli [ 'node', '/usr/local/bin/npm', 'install', 'sails-migrations' ]
2 info using npm@2.1.8
3 info using node@v0.10.33
4 verbose node symlink /usr/local/bin/node
5 verbose config Skipping project config: /Users/pivotal/.npmrc. (matches userconfig)
6 silly cache add args [ 'sails-migrations', null ]
7 verbose cache add spec sails-migrations
8 silly cache add parsed spec { raw: 'sails-migrations',
8 silly cache add scope: null,
@camelpunch
camelpunch / DataSource.groovy
Created September 29, 2014 15:14
Configuring Grails for postgres
dataSource {
pooled = true
jmxExport = true
driverClassName = "org.postgresql.Driver"
dialect = org.hibernate.dialect.PostgreSQLDialect
uri = new URI(System.env.DATABASE_URL)
username = uri.userInfo ? uri.userInfo.split(":")[0] : ""
password = uri.userInfo ? uri.userInfo.split(":")[1] : ""
url = "jdbc:postgresql://" + uri.host + uri.path
}
describe "some group" do
example "example 1" do
expect(@triangle).to have(2).sides
end
describe "some sub group" do
it "has another example, using the 'it' alias" do
expect(@circle).to be_square
end
end
I keep myself logged in on GitHub :(.