Skip to content

Instantly share code, notes, and snippets.

View remysaissy's full-sized avatar

Rémy SAISSY remysaissy

  • Teads
  • Paris
View GitHub Profile
@remysaissy
remysaissy / Chemistry.java
Created April 3, 2012 12:44
Chemistry code example
} else if (definition instanceof PropertyDateTimeDefinition) {
if (firstValue == null) {
propertyData = bof.createPropertyDateTimeData(id, (List) null);
} else if (firstValue instanceof GregorianCalendar) {
propertyData = bof.createPropertyDateTimeData(id, (List) values);
guid = None
while True:
guid = uuid.uuid1()
if self.store.exists(guid) == False:
break
self.store.set(guid, tornado.escape.json_encode(user))
@remysaissy
remysaissy / .bash_profile_docker_osx.sh
Created January 5, 2016 15:12
Shell function to let a MacOSX user load a docker-machine environment and update OSX routes to access docker0 IPs directly
# Load the docker-machine environment and update the route to let MacOSX access containers IPs.
denv() {
eval $(docker-machine env $1)
SUBNET=$(docker network inspect $(docker network ls | grep bridge | awk '{ print $1; }') | grep Subnet | awk '{ gsub(/"/, "", $2); print $2; }')
sudo route -n delete $SUBNET
@remysaissy
remysaissy / clone-jdk10.sh
Created December 11, 2018 21:37 — forked from jasontedor/clone-jdk10.sh
Cloning the OpenJDK sources
#!/bin/bash
hg clone http://hg.openjdk.java.net/jdk10/jdk10 && cd jdk10 && chmod +x get_source.sh && ./get_source.sh