Skip to content

Instantly share code, notes, and snippets.

@pcambra
pcambra / gist:3885044
Created October 13, 2012 15:38 — forked from just-digital/gist:1868435
A .vimrc file for Drupal. Sets correct tabs configuration and a few other gems. Also includes function from Aron Novak (http://drupal.org/user/61864) sourced at http://vim.wikia.com/wiki/Remove_unwanted_spaces which will remove trailing white space upon
set nocompatible
syntax on
filetype on
filetype plugin on
filetype indent on
set sidescroll=1
set sidescrolloff=3
#!/bin/bash
function drupal-install() {
sudo rm -rf sites/default;
sudo git checkout -- sites/default;
sudo chmod -R 777 sites/default;
sudo chown -R `whoami` sites/default;
sudo git checkout -- sites/default;
sudo chown -R `whoami` sites/default;
#exit;
<target name="behat" description="Run Scenario with Behat" depends="load-properties, setup-dirs, clean">
<property name="behat.basedir" value="${project.basedir}/tests/behat"/>
<exec executable="behat">
<arg line=" --config='${behat.basedir}/behat.yml' --profile='ci' --format='junit' --out='${project.logdir}/behat' ${behat.basedir}/features" />
</exec>
</target>
limit maxproc 512 1024
limit maxfiles 1024 2048
limit maxfiles 8192 20480
limit maxproc 1000 2000
limit maxfiles 20480 30480
limit maxproc 1000 2000
### Keybase proof
I hereby claim:
* I am pcambra on github.
* I am pcambra (https://keybase.io/pcambra) on keybase.
* I have a public key whose fingerprint is 2227 2DE6 2288 E442 9F53 E7D4 419D F417 CA48 27F8
To claim this, I am signing this object:
<?php
use Drupal\Core\Config\Schema\SchemaCheckTrait;
/**
* Implements hook_drush_command().
*/
function ef_drush_command() {
$items['schema-validate'] = [
'description' => dt('Validates all config schemaj'),
];
{
"name": "mynamespace/myproject",
"description": "Example composer file with provides",
"repositories": [
{
"type": "composer",
"url": "http://drupal-packagist.webflo.io/"
},
{
"type": "package",
{
"name": "mynamespace/myproject",
"description": "Composer file example",
"repositories": [
{
"type": "composer",
"url": "http://drupal-packagist.webflo.io/"
},
{
"type": "package",
@pcambra
pcambra / boot2docker-nfs.rb
Last active August 29, 2015 14:27 — forked from mattes/boot2docker-nfs.rb
docker-machine/ boot2docker with NFS instead of vboxsf
#!/usr/bin/env ruby
# Usage
# $ docker-machine create my-machine123 -d virtualbox
# $ ruby <(curl -L https://git.io/vvvco) my-machine123
# https://gist.github.com/mattes/4d7f435d759ca2581347
require 'erb'
bootlocalsh = %Q(#/bin/bash
@pcambra
pcambra / check-mandatory-fields.php
Last active October 14, 2015 13:22
Look for empty mandatory fields
<?php
/**
* Implements hook_menu().
*/
function {my_module}_menu() {
$items = array();
$items['check-mandatory-fields'] = array(
'title' => 'Mandatory content missing',