most of these require logout/restart to take effect
# Enable character repeat on keydown
defaults write -g ApplePressAndHoldEnabled -bool false
# Set a shorter Delay until key repeat
// Released under MIT license: http://www.opensource.org/licenses/mit-license.php | |
$('[placeholder]').focus(function() { | |
var input = $(this); | |
if (input.val() == input.attr('placeholder')) { | |
input.val(''); | |
input.removeClass('placeholder'); | |
} | |
}).blur(function() { | |
var input = $(this); |
/* The API controller | |
Exports 3 methods: | |
* post - Creates a new thread | |
* list - Returns a list of threads | |
* show - Displays a thread and its posts | |
*/ | |
var Thread = require('../models/thread.js'); | |
var Post = require('../models/post.js'); |
<?php | |
namespace Asso\BookBundle\Form; | |
use Symfony\Component\Validator\Constraints as Assert; | |
use Symfony\Component\Validator\ExecutionContext; | |
/** | |
* @Annotation | |
*/ |
Awesome PHP has been relocated permanently to its own Github repository. No further updates will made to this gist.
Please open an issue for any new suggestions.
Just some quick notes on how to create a hackathon, super simple really.
#!/bin/bash | |
while : | |
do | |
clear | |
git --no-pager log -$1 --graph --all --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --date=relative | |
sleep 1 | |
done |
#!/bin/bash | |
while : | |
do | |
clear | |
git --no-pager log --graph --pretty=oneline --abbrev-commit --decorate --all $* | |
sleep 1 | |
done |