I hereby claim:
- I am totallymike on github.
- I am totallymike (https://keybase.io/totallymike) on keybase.
- I have a public key whose fingerprint is 2605 7D7A BEFD F7EC 8E03 4271 093C A226 E362 4CE1
To claim this, I am signing this object:
var assert = require('assert') | |
, cradle = require('cradle') | |
, conn = new(cradle.Connection)('https://myCouch.couch',443,{ | |
auth: {username: "mike", password: "pass"}}) | |
, db = conn.database('articles'); | |
function saveDoc(doc) { | |
db.save(doc.data, printResult); | |
} |
db.query(statement, function (err, res) { | |
if (err) { | |
throw new Error(err); | |
} else { | |
// Do normal stuff. | |
} | |
}); | |
db.query(statement, function (err, res) { | |
if (err) { |
# input(a string) prints the string as the prompt, then listens to stdin | |
# int() converts strings (what you get from stdin) to integers | |
age = int( input("Enter your age: ") ) | |
if age > 64: | |
print("You're old") | |
elif age > 17: | |
print("You can vote!") | |
else: |
class Foo | |
attr_reader :stuff | |
def initialize(stuff) | |
@stuff = stuff | |
end | |
def bar | |
sock = TCPSocket.new('127.0.0.1', 1337) | |
stuff.each do |thing| |
Rack::File headers parameter replaces cache_control after Rack 1.5. | |
.F | |
Failures: | |
1) CategoriesController POST create role authorization prevents non-administrators from creating new categories | |
Failure/Error: let (:user) { users(:miketheboss) } | |
ActiveRecord::RecordNotFound: | |
Couldn't find User with id=702598363 | |
# ./spec/controllers/categories_controller_spec.rb:15:in `block (3 levels) in <top (required)>' |
class User < ActiveRecord::Base | |
attr_accessible :role_id, :as => :admin | |
belongs_to :role | |
end | |
class Role < ActiveRecord::Base | |
has_many :users | |
end | |
class UsersController < ApplicationController |
#!/bin/bash | |
### BEGIN INIT INFO | |
# Provides: nginx | |
# Required-Start: $all | |
# Required-Stop: $all | |
# Default-Start: 2 3 4 5 | |
# Default-Stop: 0 1 6 | |
# Short-Description: starts the nginx web server | |
# Description: starts nginx using start-stop-daemon |
num calls time self name | |
----------------------------------------------------------------------------------- | |
1) 1 384.85 384.85 69.98% 384.75 384.75 69.96% nvm_die_on_prefix | |
2) 1 548.11 548.11 99.67% 89.53 89.53 16.28% nvm | |
3) 1 73.61 73.61 13.39% 73.61 73.61 13.39% nvm_ensure_version_installed | |
4) 1 1.69 1.69 0.31% 1.69 1.69 0.31% nvm_supports_source_options | |
5) 3 0.31 0.10 0.06% 0.31 0.10 0.06% nvm_has | |
6) 1 0.02 0.02 0.00% 0.02 0.02 0.00% nvm_is_iojs_version | |
----------------------------------------------------------------------------------- |
I hereby claim:
To claim this, I am signing this object:
package com.pretend.myforklift | |
import com.liyaos.forklift.slick.{ SlickCodegen, SlickMigrationCommandLineTool, SlickMigrationCommands, SlickMigrationManager } | |
import scala.io.StdIn | |
trait MyMigrationCommands extends SlickMigrationCommands | |
with MyMigrationFilesHandler { | |
this: SlickMigrationManager with SlickCodegen => |