Skip to content

Instantly share code, notes, and snippets.

View raul782's full-sized avatar

Raul Rodriguez raul782

View GitHub Profile
.fc {
direction: ltr;
text-align: left; }
.fc table {
border-collapse: collapse;
border-spacing: 0; }
.fc .btn {
line-height: 1.2em; }
html .fc {
# to install the latest stable version:
brew install scala --with-docs
# to install scala-2.10:
brew install https://raw.github.com/gist/4340744/scala.rb --with-docs
# to switch versions (from https://github.com/mxcl/homebrew/wiki/External-Commands):
brew switch scala 2.9.2
brew switch scala 2.10.0
@raul782
raul782 / pr.md
Last active August 29, 2015 14:06 — forked from piscisaureus/pr.md

Locate the section for your github remote in the .git/config file. It looks like this:

[remote "origin"]
	fetch = +refs/heads/*:refs/remotes/origin/*
	url = git@github.com:joyent/node.git

Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/* to this section. Obviously, change the github url to match your project's URL. It ends up looking like this:

@raul782
raul782 / DateRange.php
Last active August 29, 2015 14:07 — forked from havvg/DateRange.php
<?php
namespace Ormigo\Bundle\OrmigoBundle\Form\Model;
use DateTime;
class DateRange
{
/**
* @var DateTime
# ~/.gitconfig from @boblet
# initially based on http://rails.wincent.com/wiki/Git_quickstart
[core]
excludesfile = /Users/oli/.gitignore
legacyheaders = false # >git 1.5
quotepath = false
# http://stackoverflow.com/questions/136178/git-diff-handling-long-lines
pager = less -r
# if ↑ doesn’t work, try: pager = less -+$LESS -FRX
(function () {
var scheme = (("https:" == document.location.protocol) ? "https" : "http");
var adnxs_domain = 'secure.adnxs.com';
var aol_domain = 'secure.leadback.advertising.com';
var rule = ["*", "*"];
if (scheme=='http') { adnxs_domain = 'ib.adnxs.com'; aol_domain = 'leadback.advertising.com';}
var el = document.createElement("div");
el.style["width"] = "1px";
el.style["height"] = "1px";
el.style["display"] = "inline";
@raul782
raul782 / gist:c31328b99c6adfb81f45
Created November 30, 2015 00:26 — forked from mlhales/gist:5785725
Install OpenCV with Nvidia CUDA, and Homebrew Python support on the Mac.

#OpenCV on the Mac with Nvidia CUDA and Python support using Homebrew

##Prerequisites

  • XCode
  • CUDA
  • Homebrew
    • CMake
    • GCC 4.5+
  • Python
@raul782
raul782 / .travis.yml
Created December 13, 2015 23:11
Testing Scala programs with Travis CI on OS X
language: java
env:
- SCALA_VERSION=2.11.7
os:
- osx
script:
- ./sbt "++$SCALA_VERSION" test
matrix:
include:
- env: SCALA_VERSION=2.11.7
@raul782
raul782 / sql-mongo_comparison.md
Created September 1, 2017 15:46 — forked from aponxi/sql-mongo_comparison.md
MongoDb Cheat Sheets

SQL to MongoDB Mapping Chart

SQL to MongoDB Mapping Chart

In addition to the charts that follow, you might want to consider the Frequently Asked Questions section for a selection of common questions about MongoDB.

Executables

The following table presents the MySQL/Oracle executables and the corresponding MongoDB executables.

@raul782
raul782 / scala unwrap collection
Created December 7, 2017 21:00 — forked from tommilimmot/scala unwrap collection
scala: pass List/Collection of arguments to Function with argument type (String, String) *, such as play.api.libs.ws.WS.WSRequestHolder.withQueryString()
val argumentList = List("arg1"->"val1", "arg2"->"val2", "arg3"->"val3")
// repl> argumentList: List[(String, String)] = List((arg1,val1), (arg2,val2), (arg3,val3))
// from play 2.1 scala api
// def withQueryString(parameters: (String, String)*): WSRequestHolder
// can't pass List[(String, String)] to function because it expects type (String, String)
// unwrap collection (List) with : _*
play.api.libs.ws.WS.url("http://localhost").withQueryString(argumentList : _*).get