Skip to content

Instantly share code, notes, and snippets.

View niquola's full-sized avatar

Nikolai Ryzhikov niquola

View GitHub Profile
@niquola
niquola / libpq_multirow_insert.cc
Created July 30, 2018 21:27 — forked from Meekohi/libpq_multirow_insert.cc
Example of a multi-row insert using libpq
#include <stdio.h>
#include <iostream>
using namespace std;
#include "opencv2/core/core.hpp"
#include "opencv2/features2d/features2d.hpp"
#include "opencv2/nonfree/features2d.hpp"
#include "opencv2/highgui/highgui.hpp"
#include "opencv2/nonfree/nonfree.hpp"
using namespace cv;
#!/usr/bin/sh
set -e
sudo apt-get install openjdk-7-jdk git-core wget -y # Ubuntu 12.04 meets no problem
wget --no-check-certificate -O ~/bin/lein https://raw.github.com/technomancy/leiningen/preview/bin/lein
chmod 755 ~/bin/lein
# Add ~/bin to your $PATH, it has been done if in Ubuntu 12.04
lein # the first time it will install itself
grep -rl 'Constant::' ./ | xargs sed -i 's/Constant::\(\w\+\)/\1Constant/g'
@niquola
niquola / rails31init.md
Created May 24, 2011 21:11 — forked from jraines/rails31init.md
Rails 3.1 with Rspec, Cucumber, Factory Girl, Haml, Devise, and Simple Form

Install Rails 3.1 RC

gem install rails --pre

generate new app, skipping Test::Unit file generation

rails new my_app -T

Set up Gemfile