Skip to content

Instantly share code, notes, and snippets.

View allgood2386's full-sized avatar

Richard Allen allgood2386

  • Bixal
  • Northern Virgina
View GitHub Profile
<?php
$date=strtotime($entity->field_event_date['und'][0]['value']);
print '<div class="event-date-styled">';
print '<span class="event-date-styled-day">'.format_date($date,'day').'</span>';
print '<span class="event-date-styled-inner-wrapper">';
print '<div class="event-date-styled-month">'.format_date($date,'month').'</div>';
print '<div class="event-date-styled-year">'.format_date($date,'year').'</div>';
print '</span></div>';
?>
stderr: Failed to fetch http://security.ubuntu.com/ubuntu/pool/main/a/apache2/apache2.2-bin_2.2.22-1ubuntu1.3_amd64.deb 404 Not Found [IP: 91.189.91.15 80]
Failed to fetch http://security.ubuntu.com/ubuntu/pool/main/a/apache2/apache2-utils_2.2.22-1ubuntu1.3_amd64.deb 404 Not Found [IP: 91.189.91.15 80]
Failed to fetch http://security.ubuntu.com/ubuntu/pool/main/a/apache2/apache2.2-common_2.2.22-1ubuntu1.3_amd64.deb 404 Not Found [IP: 91.189.91.15 80]
Failed to fetch http://security.ubuntu.com/ubuntu/pool/main/a/apache2/apache2-mpm-prefork_2.2.22-1ubuntu1.3_amd64.deb 404 Not Found [IP: 91.189.91.15 80]
Failed to fetch http://security.ubuntu.com/ubuntu/pool/main/a/apache2/apache2_2.2.22-1ubuntu1.3_amd64.deb 404 Not Found [IP: 91.189.91.15 80]
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?
---
- name: Ensure git is installed (Debian).
apt: name={{ item }} state=installed
with_items: git_packages
# Install git from source when git_install_from_source is true.
- include: install-from-source.yml
when: git_install_from_source == true
<?php
/**
* Implements hook_form_alter().
* todo: change weight to something dynamic. IF we reorder anything it will be out of place.
*/
function add_teach_embed_form_alter(&$form, &$form_state, $form_id) {
if ($form_id === 'school_node_form') {
$form['add_teacher'] = array(
'#type' => 'fieldset',
'#title' => t('Add Teachers'),
<?php
/**
* @file
* add_teach_embed.module
* Create a form which we add to the school create/edit forms. Provides a submit hook to invite these users to join.
*/
/**
* Implements hook_form_alter().
_module_implements_alter
<?php
/**
* @file translation_form_changes.module
* TODO: Enter file description here.
*/
/**
* Implements hook_form_alter().
*/
#!/bin/sh
# Some things taken from here
# https://github.com/mathiasbynens/dotfiles/blob/master/.osx
# Set the colours you can use
black='\033[0;30m'
white='\033[0;37m'
red='\033[0;31m'
green='\033[0;32m'
$aliases['vagrant'] = array(
'root' => '/var/www/docroot',
'uri' => 'somthing.dev',
'remote-user' => 'vagrant',
'remote-host' => 'something.dev',
'ssh-options' => "-p 22 -i " . $home . "/.vagrant.d/insecure_private_key",
);