I hereby claim:
- I am shreeve on github.
- I am shreeve (https://keybase.io/shreeve) on keybase.
- I have a public key ASBI8x-VoitCK6fVsyz0tNSu4A-NsuCh6ri6I1-p1t0gXAo
To claim this, I am signing this object:
{ ServiceProvider } = require '@adonisjs/fold' | |
AdonisMongoose = require 'mongoose' | |
module.exports = class MongooseProvider extends ServiceProvider | |
register: -> | |
@app.singleton 'Adonis/Addons/AdonisMongoose', => | |
Config = @app.use 'Adonis/Src/Config' | |
mongoHost = Config.get 'mongo.host', '127.0.0.1' | |
mongoPort = Config.get 'mongo.port', '27017' | |
mongoDb = Config.get 'mongo.db' , 'test' |
I hereby claim:
To claim this, I am signing this object:
#!/usr/bin/ruby -E binary | |
# alias lscleanup="/System/Library/Frameworks/CoreServices.framework/Frameworks/LaunchServices.framework/Support/lsregister -kill -r -domain local -domain system -domain user && killall Finder" | |
apps = {} | |
uses = {} | |
text = %x{`locate lsregister` -dump} | |
rows = text.split('-' * 80); rows.shift |
FROM ubuntu-debootstrap:14.04 | |
# Nodejs needed for ruby asset pipeline | |
RUN apt-get update -y \ | |
&& apt-get install -y \ | |
curl \ | |
libpq-dev \ | |
&& curl -sSL https://deb.nodesource.com/setup_0.12 | bash - \ | |
&& apt-get install -y nodejs \ | |
&& apt-get autoremove -y \ |
#!/usr/bin/env ruby | |
# ============================================================================= | |
# UPDATE as of June 15, 2015: See the bindings gem at: | |
# | |
# https://rubygems.org/gems/bindings | |
# ============================================================================= | |
# ============================================================================= | |
# Quick proof-of-concept of an Fiddle-based binding_of_caller (no compiling!) |
# See https://gist.github.com/nanki/1336545 | |
require 'ffi' | |
module FFI::Ruby | |
class Value | |
class << self | |
extend ::FFI::Library | |
ffi_lib 'ruby' |
#!/usr/bin/env ruby | |
# ============================================================================= | |
# Quick proof-of-concept of an FFI-based binding_of_caller (no compiling!) | |
# | |
# Author: Steve Shreeve <[email protected]> | |
# Basis: binding_of_caller and ffi gems | |
# Date: 28 May 2015 | |
# | |
# Legal: MIT License |
#!/usr/bin/env bash | |
watch=/tmp/watch | |
ready=/tmp/ready | |
rm -f $watch $ready | |
mkfifo $watch | |
# reap all on exit | |
trap "exit" INT TERM |
# RESTful API | |
# | |
# +--------+-------------------+---------+---------+----------+-----------+ | |
# | METHOD PATH | ACTION | PAYLOAD | TEMPLATE | REDIRECT | | |
# + -------+-------------------+---------+---------+----------+-----------| | |
# | GET | /orders | index | | index | | | |
# | GET | /orders/new | new | | edit | | | |
# | GET | /orders/4;edit | edit | | edit | | | |
# | GET | /orders/4 | show | | show | | | |
# + -------+-------------------+---------+---------+----------+-----------+ |