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 | |
# Check arguments and requirements. | |
if [ ${#@} -lt 1 ]; then | |
echo "This script expects one argument (site machine name)." | |
exit 1 | |
fi | |
if [ -x ${HOME}/.my.cnf ]; then | |
echo "This script requires ${HOME}/.my.cnf." |
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: Luigi Guevara <@killua99> | |
# | |
# Use | |
# For a Simple Tag changelog | |
# ./changelog > CHANGELOG.txt | |
# | |
# For a current dev branch with the old tag log | |
# ./changelog 7.x-2.x > CHANGELOG.txt |
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
// ==UserScript== | |
// @name Show Instagram photos | |
// @namespace http://killua.me/ | |
// @version 0.1 | |
// @description This allows instagram pictures to be shown like normal | |
// @match http*.twitter.com/* | |
// @copyright 2014+, Luigi Guevara | |
// @require https://code.jquery.com/jquery-1.11.1.min.js | |
// @grant none | |
// ==/UserScript== |
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 | |
/** | |
* Implements hook_menu(). | |
*/ | |
function custom_two_form_menu() { | |
$items = array(); | |
$items['custom'] = array( | |
'title' => 'Custom', |
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 | |
/** | |
* Preprocess page. | |
*/ | |
function mytheme_preprocess_page(&$vars) { | |
drupal_add_css(path_to_theme() . '/css/foo.css', 'theme', 'all'); | |
$vars['styles'] = drupal_get_css(); |
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 | |
DATE=`date +%Y%m%d%H%M` | |
DOCROOT='/mnt/xxxx/www/xxxxxx/docroot' | |
CURRENT_DIR=`pwd` | |
CURRENT_BUILD_DIR=$CURRENT_DIR/$DATE | |
cd $DOCROOT/web | |
# drupal ce |
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
INFO global: Vagrant version: 1.8.1 | |
INFO global: Ruby version: 2.2.3 | |
INFO global: RubyGems version: 2.4.5.1 | |
INFO global: VAGRANT_OLD_ENV_XDG_MENU_PREFIX="gnome-" | |
INFO global: VAGRANT_OLD_ENV_LC_NUMERIC="C" | |
INFO global: VAGRANT_OLD_ENV_LC_PAPER="C" | |
INFO global: VAGRANT_OLD_ENV_SHELL="/bin/bash" | |
INFO global: VAGRANT_OLD_ENV_SHLVL="2" | |
INFO global: VAGRANT_OLD_ENV_USERNAME="killua" | |
INFO global: VAGRANT_OLD_ENV_PAGER="less" |
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
#Download Elementary OS from here: | |
#http://sourceforge.net/projects/elementaryos/files/stable/ | |
#First you update your system | |
sudo apt-get update && sudo apt-get dist-upgrade | |
# Second install an extra tools to download packages | |
sudo add-apt-repository ppa:apt-fast/stable | |
sudo apt-get update | |
sudo apt-get install apt-fast |
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 | |
namespace Drupal\storleden_search\Plugin\rest\resource; | |
use Drupal\Core\Entity\EntityTypeManager; | |
use Drupal\Core\Session\AccountProxyInterface; | |
use Drupal\rest\Plugin\ResourceBase; | |
use Drupal\rest\ResourceResponse; | |
use Symfony\Component\DependencyInjection\ContainerInterface; | |
use Symfony\Component\HttpKernel\Exception\AccessDeniedHttpException; |
OlderNewer