Skip to content

Instantly share code, notes, and snippets.

View ryanirelan's full-sized avatar

Ryan Irelan ryanirelan

View GitHub Profile
# Run this at your site root to upgrade EE
# Paths assume your system folder is at site root
# http://expressionengine.com/docs/installation/update.html
#!/bin/bash
# location of the release
RELEASE_PATH="/Users/ryan/Desktop/Incoming/ExpressionEngine1.6.7"
echo "Enter the name of your system folder"
# RYAN'S BASH ALIASES
alias home='cd ~'
alias c='clear'
alias ..='cd ..'
alias pg='ping google.com'
alias proj='cd ~/projects'
alias airbag='cd ~/projects/airbag'
alias l='ls -lah'
alias incoming='cd ~/Desktop/Incoming'
<p>
<textarea name="{exp:form_helper:field_grabber field_name='tip-content'}" id="{field_name}" class="textarea" rows="{rows}" onclick="setFieldName(this.name)">
{exp:form_helper:field_parser parse=""}{tip-content}{/exp:form_helper:field_parser}
</textarea>
</p>
<input type="hidden" name="{exp:form_helper:field_grabber field_name='tip-content' which='format'}" value="none" />
require 'net/http'
require 'uri'
# /api/v1/:format/new
# /api/v1/:format/gists/:user
# /api/v1/:format/:gist_id
res = Net::HTTP.post_form(URI.parse('http://gist.github.com/api/v1/xml/new'),
{ 'files[file1.ab]' => 'CONTNETS',
'files[file2.ab]' => 'contents' })
#!/bin/sh
cd ~/work
for dir in `find . -type d -maxdepth 1 -mindepth 1`; do cd $dir; git pull origin master; cd -; done
# !/bin/bash
# Set up an new github repository
GITHUB_USERNAME="timkelty"
# from github instructions page after creating a repo
mkdir "$1"
cd "$1"
git init
touch README
#!/bin/bash
# File: exp_permissions.sh
# Description: Sets permssions on a ExpressionEngine 2 install
#
# Copyright 2010 George Ornbo (Shape Shed)
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond $1 !\.(gif|jpe?g|png)$ [NC]
RewriteRule ^(.*)$ /index.php?$1 [L]
@ryanirelan
ryanirelan / gist:3320348
Created August 11, 2012 03:25 — forked from ckimrie/gist:3312619
Example extension that allows you to modify the final ExpressionEngine CP output
<?php
/**
* Modifying the final CP Output
*
* This extension demonstrates how you can access and modify the final ExpressionEngine
* CP output. It is not a hack, but it is a new technique that to my knowledge has not
* been used before in an EE addon.
*
* This has not been road tested and its side effects are unknown, so use this at your own risk.