This file contains 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
^(CVS|SCCS|vssver.?\.scc|#.*#|%.*%|_svn)$|~$|^\.(?!htaccess|jshintrc|DS_Store|gitattributes|gitignore$|.*\.yml$).*$ |
This file contains 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
function uniqid (prefix, more_entropy) { | |
// + original by: Kevin van Zonneveld (http://kevin.vanzonneveld.net) | |
// + revised by: Kankrelune (http://www.webfaktory.info/) | |
// % note 1: Uses an internal counter (in php_js global) to avoid collision | |
// * example 1: uniqid(); | |
// * returns 1: 'a30285b160c14' | |
// * example 2: uniqid('foo'); | |
// * returns 2: 'fooa30285b1cd361' | |
// * example 3: uniqid('bar', true); | |
// * returns 3: 'bara20285b23dfd1.31879087' |
This file contains 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
#!/bin/bash | |
usage="Usage: mysql_csv_dump database_name username" | |
err[1]="Invalid command" | |
# Check for database name argument | |
if [ -z "$1" ] | |
then | |
echo ${err[1]} |
This file contains 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
#!/bin/bash | |
usage="Usage: mysql_collation_to_utf8 database_name username" | |
err[1]="Invalid command" | |
# Check for database name argument | |
if [ -z "$1" ] | |
then | |
echo ${err[1]} |
This file contains 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
#!/bin/bash | |
usage="Usage: mysqldumpgz database_name username" | |
err[1]="Invalid command" | |
# Check for database name argument | |
if [ -z "$1" ] | |
then | |
echo ${err[1]} |
This file contains 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
#!/bin/bash | |
# author: Duane Johnson | |
# email: duane.johnson@gmail.com | |
# date: 2008 Jun 12 | |
# license: MIT | |
# | |
# Based on discussion at http://kerneltrap.org/mailarchive/git/2007/11/12/406496 | |
pushd . >/dev/null |
This file contains 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
<?php | |
/** | |
* Displays the current migration version of the database | |
* | |
* @version 1.0 | |
* @author Ain Tohvri <at@interactive-pioneers.de> | |
* @see sfBaseTask | |
*/ | |
class currentMigrationVersionTask extends sfBaseTask |
This file contains 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
#!/usr/bin/env ruby | |
# encoding: utf-8 | |
# By Uğur Özyılmazel, @vigobronx | @ugurozyilmazel | |
# http://vigodome.com | http://ugur.ozyilmazel.com | http://github.com/vigo | |
def get_paged_memory_usage(match_string, paging=4096) | |
mvar = 3 | |
if match_string.split(/[^\w]/).length > 1 | |
mvar = 4 |
This file contains 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
<?php | |
class MyBaseForm extends sfFormSymfony | |
{ | |
public function getErrors() | |
{ | |
$errors = array(); | |
foreach ($this as $form_field) | |
{ |
This file contains 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
<?php | |
class sfWidgetFormSelectRadioSingleable extends sfWidgetFormSelectRadio | |
{ | |
public function formatChoices($name, $value, $choices, $attributes) | |
{ | |
$onlyChoice = !empty($attributes['only_choice']) ? $attributes['only_choice'] : false; | |
unset($attributes['only_choice']); | |
if ($onlyChoice) |