Skip to content

Instantly share code, notes, and snippets.

View waxzce's full-sized avatar

Quentin ADAM waxzce

View GitHub Profile

Keybase proof

I hereby claim:

  • I am waxzce on github.
  • I am waxzce (https://keybase.io/waxzce) on keybase.
  • I have a public key whose fingerprint is A1F3 CF15 85FA F589 CD06 C35C CECD 821C E6AD AE5D

To claim this, I am signing this object:

#!/bin/bash
echo "hostname"
hostname
echo "--------------------------------------------------------------"
echo "uname -a"
uname -a
echo "--------------------------------------------------------------"
echo "lsb_release -a"
lsb_release -a
@waxzce
waxzce / build.sbt
Last active January 14, 2018 18:21
name := """minimal-scala"""
version := "1.0"
scalaVersion := "2.11.7"
// Change this to another test framework if you prefer
libraryDependencies += "org.scalatest" %% "scalatest" % "2.2.4" % "test"
// Uncomment to use Akka
swagger: '2.0'
info:
title: Evolutions MarketPrice France | Mise en place WS avec Cobredia
description: L’objectif de ce document est de décrire la mise en place d’une interface via Web-Service entre MarketPrice (MP) et la future plate-forme Web du Groupe COBREDIA. Le WS devant être développé par MP, il est nécessaire de faire de rédiger la documentation descriptive du WS mais aussi d’apporter des modifications à l’outil MP de façon à bien prendre en compte toutes les données mises à disposition.
version: "1.0.0"
# the domain of the service (dev)
host: dev2.marketprice-fr.synten.com
# array of all schemes that your API supports
schemes:
- http
@ 10800 IN A 217.70.184.38
adc-fr110-243250.net 3600 IN A 62.210.121.147
adc-fr110-7456cb.net 3600 IN A 62.210.121.146
ars-fr110-193533.net 3600 IN A 62.210.121.148
cctf 3600 IN A 212.129.42.17
console 3600 IN A 62.210.121.151
domain 600 IN A 62.210.121.146
domain 600 IN A 88.190.19.132
domain.mtl 600 IN A 68.71.34.20
domain.mtl 600 IN A 68.71.34.21
@waxzce
waxzce / AController.scala
Created September 23, 2013 04:24
this is the code example from my talks at scala user group of Tokyo
package controllers
import play.api._
import play.api.mvc._
import play.api.libs.iteratee.Iteratee
import play.api.libs.iteratee.Input
import play.api.libs.iteratee.Done
import play.api.libs.iteratee.Cont
import scalax.file.Path
import views.html.defaultpages.badRequest
package filters
import play.api.mvc._
import controllers.Default
import play.api.libs.iteratee.Enumerator
import play.Logger
object CorsFilter extends Filter {
package utils
object sha256 {
class StringSHAHelper(str: String) {
val md = java.security.MessageDigest.getInstance("SHA-256")
def sha_256 = (new sun.misc.BASE64Encoder).encode(md.digest(str.getBytes))
}
implicit def stringWrapper(string: String) = new StringSHAHelper(string)
}
@waxzce
waxzce / git-gitolite-clone
Created September 15, 2012 17:56
Clone all git repo from a gitolite
#!/bin/bash
# USAGE : git gitolite-clone <user@host>
GITOLITE_URL=$1
GOGO=0
for i in $(ssh $GITOLITE_URL info)
do
if [ $GOGO -eq 1 ] ; then
if [[ $i != "R" && $i != "W" ]] ; then
@waxzce
waxzce / gist:1617346
Created January 15, 2012 21:09
find dups id in your html
var find_dbl_ids = function(){
var names = {};
$('*[id]').each(function(i, e){
var iid = $(e).attr('id');
if(iid != null && iid != ''){
if(names[iid] == undefined){
names[iid] = 1;
}else{
names[iid] = names[iid]+1;