This file contains hidden or 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
module ModeratedModel | |
extend ActiveSupport::Concern | |
included do | |
belongs_to :admin_approval | |
scope :moderated, where(moderated: true) | |
scope :not_moderated, where(moderated: false) | |
end | |
module ClassMethods |
This file contains hidden or 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
NSInteger numberOfRows = [tableView numberOfRows]; | |
if (numberOfRows > 0) | |
[tableView scrollRowToVisible:numberOfRows - 1]; |
This file contains hidden or 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
GOARCH=amd64 | |
GOBIN=/usr/local/bin | |
GOOS=darwin | |
GOROOT=/usr/local/Cellar/go/1.0.1 |
This file contains hidden or 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
(function() { | |
var $screen, animate, camera, define_ships, init_simulation, mesh, render, renderer, scene; | |
$screen = $('#viewscreen'); | |
renderer = mesh = scene = camera = null; | |
init_simulation = function() { | |
var cobra_geom, fov, material, screenHeight, screenWidth; | |
screenWidth = $screen.width(); |
This file contains hidden or 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
/*-- Defined object types, their point --*/ | |
/*-- co-ordinates and facet orders in --*/ | |
/*-- anitclockwise fashion as viewed --*/ | |
static int TRIANGLEpoints[][]= /* triangle for explosions */ |
This file contains hidden or 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
rake test | |
WARNING: 'require 'rake/rdoctask'' is deprecated. Please use 'require 'rdoc/task' (in RDoc 2.4.2+)' instead. | |
at /home/stephen/.rvm/gems/rbx-head@global/gems/rake-0.9.2.2/lib/rake/rdoctask.rb | |
rake/gempackagetask is deprecated. Use rubygems/package_task instead | |
[BUG: requested Object for unknown NativeMethod handle type] | |
/home/stephen/.rvm/rubies/rbx-head/bin/rbx(_ZN8rubinius3bugEPKc+0x80) [0x81c4180] | |
/home/stephen/.rvm/rubies/rbx-head/bin/rbx(rb_define_const+0x18f) [0x8388bff] | |
/home/stephen/Documentos/Projetos/Guilda/ci/ruby-libvirt-0.4.0/ext/libvirt/_libvirt.so(init_domain+0x18cb) [0x12c53b] | |
/home/stephen/Documentos/Projetos/Guilda/ci/ruby-libvirt-0.4.0/ext/libvirt/_libvirt.so(Init__libvirt+0x156a) [0x12521a] | |
/home/stephen/.rvm/rubies/rbx-head/bin/rbx(_ZN8rubinius16GenericArguments6invokeEPNS_5StateEPNS_12NativeMethodEPNS_23NativeMethodEnvironmentERNS_9ArgumentsE+0x1566) [0x82dfb36] |
This file contains hidden or 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
# -*- coding: utf-8 -*- | |
def ☠(n) | |
☥ = 10 | |
blacks = %w(♟ ♝ ♞ ♜ ♛ ♚) | |
whites = %w(♙ ♗ ♘ ♖ ♕ ♔) | |
n.times { puts "yaaaaaaar" } | |
puts ☥ | |
This file contains hidden or 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
# -*- coding: utf-8 -*- | |
def ☠(n) | |
n.times { puts "yaaaaaaar" } | |
end | |
☠(10) |
This file contains hidden or 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
(foreign-declare "#include <mongo.h>") | |
(define-foreign-type Mongo c-pointer) | |
(define mongo-create | |
(foreign-lambda* c-pointer () | |
"mongo* mongo; | |
mongo = malloc(sizeof(mongo)); | |
C_return(mongo);")) |
This file contains hidden or 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
;;; Collect Postgresql statistics | |
(use postgresql) | |
(define connection-string (make-parameter '((host . "<ip>") | |
(user . "<user here>") | |
(dbname . "<db name here>")))) | |
(define conn (connect (connection-string))) |
NewerOlder