Skip to content

Instantly share code, notes, and snippets.

View czj's full-sized avatar

Clément Joubert czj

View GitHub Profile
@czj
czj / lol-shortcuts.txt
Created March 10, 2014 20:20
Raccourcis LOL Windows (chat, cast, etc...)
Standard Keyboard Shortcuts:
q,w,e,r - linked to your abilities
d,f, - linked to your summoner spells
y - locks/unlock you camera
L - shows/hides lifebars
spacebar - center's your hero on screen
b - back/recall
p - opens item shop
g - turns mouse to ping click (click anywhere on screen or hero to ping)
alt + left click - same as above
{
"binary_file_patterns":
[
"*.jpg",
"*.jpeg",
"*.png",
"*.gif",
"*.ttf",
"*.tga",
"*.dds",
ignore %r{^(public/e|tmp|log|deprecated)}
group "app" do
guard :bundler do
watch 'Gemfile'
end
guard :pow do
watch %r{^config/.+\.yml$}
watch %r{^config/environments/.+\.(rb|yml)$}
module LineWithTaxes
extend ActiveSupport::Concern
included do
validates_length_of :label, within: 2..254
validates_length_of :comment, within: 0..254, allow_blank: true
validates_numericality_of :amount_with_taxes, :amount_without_taxes
validates_numericality_of :quantity, minimum: 1, only_integer: true
validates_numericality_of :ecotax, minimum: 0
alfred://customsearch/Traduire%20en%20francais/en/utf8/noplus/https://translate.google.fr/#en/fr/{query}
alfred://customsearch/Traduire%20en%20allemand/en/utf8/noplus/https://translate.google.fr/#fr/de/{query}
alfred://customsearch/Traduire%20en%20anglais/en/utf8/noplus/https://translate.google.fr/#fr/en/{query}

Thanks to @alfredapp 's Web Search, you can call "0123456789" using OS X #Yosemite + iPhone on iOS8.1

Click this URI :

alfred://customsearch/Call%20%7Bquery%7D%20via%20iPhone/tel/utf8/noplus/tel:{query}

@czj
czj / fianet_sha1_hmac.php
Created January 16, 2015 09:41
FIANET / Certissim SHA1 + HMAC signature
#!/usr/bin/php
<?php
// Check http://cl.ly/2o0z0z1G103O for documentation on Certissim's HMAC SHA1
// First parameter = hexadecimal key
$key_hex = $argv[1];
// Second = string to get signature
$payload = $argv[2];
@czj
czj / fianet_sha1_hmac.php
Created January 16, 2015 16:06
FIA-NET / Certissim's HMAC SHA1 checksum
#!/usr/bin/php
<?php
// Check http://cl.ly/2o0z0z1G103O for documentation on Certissim's HMAC SHA1
// First parameter = hexadecimal key
$key_hex = $argv[1];
// Second = string to get signature
$payload = $argv[2];
@czj
czj / nginx
Created July 17, 2011 10:00
Ubuntu Server 10.04 init.d file for nginx (installed by Passenger)
#! /bin/sh
### BEGIN INIT INFO
# Provides: nginx
# Required-Start: $all
# Required-Stop: $all
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: starts the nginx web server
# Description: starts nginx using start-stop-daemon
@czj
czj / gist:1136386
Created August 10, 2011 08:42
Auto-login bookmarklet for Boursorama Banque (site beta août 2011)
if (window.location != 'https://www.boursorama.com/connexion.phtml')
{
window.location = 'https://www.boursorama.com/connexion.phtml';
}
else
{
document.getElementById('login').value = "";
document.getElementById('password').value = "";
document.getElementById('identification').submit();
}