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 | |
if [ "$1" = "-h" -o "$1" = "--help" -o -z "$1" ]; then cat <<EOF | |
appify v3.0.1 for Mac OS X - http://mths.be/appify | |
Creates the simplest possible Mac app from a shell script. | |
Appify takes a shell script as its first argument: | |
`basename "$0"` my-script.sh |
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
aptitude install -y git curl python-dev python-pip redis-server ruby1.9.3-full rubygems1.9.3 | |
aptitude install -y mysql-server libmysqlclient-dev | |
adduser --system --shell /bin/sh --gecos 'git version control' --group --disabled-password --home /home/git git | |
adduser --disabled-login --gecos 'gitlab system' gitlab | |
usermod -a -G git gitlab | |
su - gitlab | |
ssh-keygen -q -N '' -t rsa -f /home/gitlab/.ssh/id_rsa | |
aptitude install gitolite | |
cp /home/gitlab/.ssh/id_rsa.pub /home/git/gitlab.pub | |
su - git |
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
/** | |
* @license Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved. | |
* For licensing, see LICENSE.html or http://ckeditor.com/license | |
*/ (function () { | |
var imageDialog = function (editor, dialogType) { | |
// Load image preview. | |
var IMAGE = 1, | |
LINK = 2, | |
PREVIEW = 4, | |
CLEANUP = 8, |
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
# Ignore configuration files that may contain sensitive information. | |
sites/*/settings*.php | |
# Ignore paths that contain user-generated content. | |
sites/*/files | |
sites/*/private | |
# Ignore sublime project and development files | |
*.sublime-projectcompletions | |
*.sublime-project |
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
#live git pull | |
drush dd @alias:%git-dir | |
drush dd @alias:%work-tree | |
drush @alias exec git fetch origin | |
drush @alias exec git merge origin/master |
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
ls -l | awk '{k=0;for(i=0;i<=8;i++)k+=((substr($1,i+2,1)~/[rwx]/)*2^(8-i));if(k)printf("%0o",k);print}' |
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
# Change this to :production when ready to deploy the CSS to the live server. | |
environment = :development | |
#environment = :production | |
# In development, we can turn on the FireSass-compatible debug_info. | |
firesass = false | |
#firesass = true | |
# Location of the theme's resources. |
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
# Install Codesniffer. | |
$ sudo pear install PHP_CodeSniffer | |
# Ensure the bin folder's $PATH is set, check by executing '$ which phpcs'. | |
# Download drupal standards to a dropbox folder via git | |
# this way, a git pull to this folder will be able to upgrade coder. | |
# (From sync folder) | |
$ git clone --branch 7.x-2.x http://git.drupal.org/project/coder.git |
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 | |
// Get the url. | |
$url = 'someurl'; | |
// Ping the domain. | |
$request = drupal_http_request($url); | |
// Grab the headers form the object and set. | |
$headers = $request->headers; | |
// Drupal print. | |
dpm($headers); |
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
// Cache pages for anonymous. | |
variable_set('cache', 0); | |
// Enable block caching. | |
variable_set('block_cache', TRUE); | |
// Minimum cache time - none. | |
variable_set('cache_lifetime', 0); | |
// Cache expiry 15 minutes. | |
variable_set('page_cache_maximum_age', '900'); | |
// Page compression on. | |
variable_set('page_compression', TRUE); |
OlderNewer