Skip to content

Instantly share code, notes, and snippets.

View chamerling's full-sized avatar
🤟

Christophe Hamerling chamerling

🤟
View GitHub Profile
let _ = global._ = require("lodash");
let Benchmark = global.Benchmark = require("benchmark");
let Promise = require("bluebird");
let { Map } = require("immutable");
let { produce } = require("immer");
function getItems(count) {
let id = 1;
import { register } from 'register-service-worker';
if (process.env.NODE_ENV === 'production') {
register(`${process.env.BASE_URL}service-worker.js`, {
ready () {
console.log('Service worker is active.');
},
registered (registration) {
console.log('Service worker has been registered.');
@chamerling
chamerling / sdk-barcamp.md
Last active May 17, 2017 07:54
SDK Barcamp 🤘🏻

Missing commits

From sdk branch:

CAL

  • c1de83930e12d4289e8ed4c826e65e55212645b6

CHAT

  • 0f8f478747b1cd2303f5b431619faeb3500699e4
  • 102f92e6ff505b55497392b7328cb0e1a9661a20
@chamerling
chamerling / ES.txt
Last active November 6, 2017 16:34
Dirty ES fix for OP user search
chamerling@macbook-air-de-christophe:~/src/openpaas/rse-chamerling|CAL-605-rename-events⚡
⇒ curl -XDELETE 'http://localhost:9200/users.idx/'
{"acknowledged":true}% chamerling@macbook-air-de-christophe:~/src/openpaas/rse-chamerling|CAL-605-rename-events⚡
⇒ node ./bin/cli.js elasticsearch -t users
debug: local/SUBSCRIBE to mongodb:connectionAvailable
[CLI] INFO ElasticSearch has been configured
chamerling@macbook-air-de-christophe:~/src/openpaas/rse-chamerling|CAL-605-rename-events⚡
⇒ node ./bin/cli.js reindex -t users
@staltz
staltz / introrx.md
Last active May 3, 2024 13:00
The introduction to Reactive Programming you've been missing
@obazoud
obazoud / Dockerfile
Last active December 22, 2015 04:58
Build Docker images - Jenkins - https://index.docker.io/u/obazoud/jenkins/
# Install Jenkins 1.529 on Ubuntu 12.10
# Build
# sudo docker run -p 8080:8080 -i -t obazoud/jenkins /bin/bash
# Install
# sudo docker pull obazoud/jenkins
# Use
# cd /opt && java -jar jenkins.war
#!/usr/bin/env node
var fs = require('fs');
function getTemperature (device) {
fs.readFile('/sys/bus/w1/devices/' + device + '/w1_slave', 'utf8', function (err, data) {
var output = data.match(/t=(\d+)/);
var calc = output[1] / 1000;
@chamerling
chamerling / gist:4232276
Created December 7, 2012 10:08
Get all PLAY repositories
# Install JSON gem before: gem install json
curl -s https://api.github.com/orgs/play-project/repos?per_page=200 | ruby -rubygems -e 'require "json"; JSON.load(STDIN.read).each { |repo| %x[git clone #{repo["ssh_url"]} ]}'
@letmaik
letmaik / .travis.yml
Last active December 15, 2021 23:10
Deploy snapshots to Sonatype after Travis CI build
language: java
env:
global:
- SONATYPE_USERNAME=yourusername
- secure: "your encrypted SONATYPE_PASSWORD=pass"
after_success:
- python addServer.py
- mvn clean deploy --settings ~/.m2/mySettings.xml