This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
case class CartLine(id: Option[Long], start: DateTime, end: DateTime, saisonId: Long, chambreId: Long, quantity: Int, unityPrice: BigDecimal, tax: BigDecimal, cartId: Option[Long]) | |
case class Cart(id: Option[Long], createdAt: DateTime) | |
object Cart { | |
type CartWithLine = (Cart, List[CartLine]) | |
} | |
implicit val cartLineFormat = Json.format[CartLine] | |
implicit val cartWithLineFormat = Json.format[CartWithLine] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for file in *.JPG; do mv -- "$file" "$(expr "$file" : '\(.*\)\.JPG').jpg"; done |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cat sites-enabled/www.cestpasdur.com | |
<VirtualHost *:80> | |
ServerName cestpasdur.com:80 | |
ServerAlias nexus.cestpasdur.com | |
UseCanonicalName Off | |
ServerAdmin "[email protected]" | |
CustomLog /var/www/www.cestpasdur.com/logs/nexus_access_log plesklog |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
alias idea='/home/applications/idea-IU-129.451/bin/idea.sh > /dev/null 2>&1 &' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Recipe for play-2.1.1-RC2 | |
require 'formula' | |
class Play < Formula | |
homepage 'http://www.playframework.org/' | |
url 'http://downloads.typesafe.com/play/2.1.1-RC2/play-2.1.1-RC2.zip' | |
md5 'ef4b378dae9c6a8711f9f5395e626ca3' | |
version '2.1.1-RC2' | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import com.google.common.util.concurrent.*; | |
import org.junit.Test; | |
import org.slf4j.Logger; | |
import org.slf4j.LoggerFactory; | |
import java.util.concurrent.Callable; | |
import java.util.concurrent.ExecutionException; | |
import java.util.concurrent.Executors; | |
public class FutureTest { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Grab('org.fluttercode.datafactory:datafactory:0.8') | |
@GrabConfig(systemClassLoader=true) | |
import org.fluttercode.datafactory.impl.DataFactory; | |
@Grab('org.elasticsearch:elasticsearch:0.19.0') | |
@GrabConfig(systemClassLoader=true) | |
import org.elasticsearch.client.Client; | |
import org.elasticsearch.node.Node; | |
import org.elasticsearch.action.bulk.BulkRequestBuilder; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#{extends 'main.html' /} | |
#{set title:'Home' /} | |
<script src="@{'/public/javascripts/require-1.0.4.js'}" type="text/javascript" charset="${_response_encoding}"></script> | |
<script> | |
require([ | |
"/public/javascripts/order.js!/public/javascripts/json2.js", | |
"/public/javascripts/order.js!/public/javascripts/jquery-1.7.1.min.js", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
new File("D://myPath/").eachDirRecurse() { dir -> | |
dir.eachFileMatch(~/.*.properties/) { file -> | |
file.eachLine{ln -> | |
if ( ln =~/\.bat$/) { | |
path = ln.split("=")[1] | |
if (path.startsWith("D:/")){ | |
if (!new File(path).exists()){ | |
println file.path+" => "+ ln | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Trouver une exception dans un répertoire | |
find . -name "*" | xargs grep ClassCastException | |
//Compresser un répertoire | |
tar cvzf plop.tgz lerepertoire |