Skip to content

Instantly share code, notes, and snippets.

💪
Testing out the new Github status!

Adam Chapman chapmandu

💪
Testing out the new Github status!
Block or report user

Report or block chapmandu

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@chapmandu
chapmandu / lang-cfml.json
Created Apr 12, 2017
cfwheels 2.x vscode snippets
View lang-cfml.json
{
/*
// Place your snippets for CFML here. Each snippet is defined under a snippet name and has a prefix, body and
// description. The prefix is what is used to trigger the snippet and the body will be expanded and inserted. Possible variables are:
// $1, $2 for tab stops, $0 for the final cursor position, and ${1:label}, ${2:another} for placeholders. Placeholders with the
// same ids are connected.
// Example:
"Print to console": {
"prefix": "log",
"body": [
@chapmandu
chapmandu / install_ruby_rails_ubuntu.txt
Created Apr 11, 2016
Install Ruby & Rails on Ubuntu
View install_ruby_rails_ubuntu.txt
# ruby & rails dependencies
sudo apt-get update
sudo apt-get install git-core curl zlib1g-dev build-essential libssl-dev libreadline-dev libyaml-dev libsqlite3-dev sqlite3 libxml2-dev libxslt1-dev libcurl4-openssl-dev python-software-properties libffi-dev
# rbenv
cd
git clone https://github.com/rbenv/rbenv.git ~/.rbenv
echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.bashrc
echo 'eval "$(rbenv init -)"' >> ~/.bashrc
exec $SHELL
@chapmandu
chapmandu / web.xml
Created Jun 9, 2015
Lucee Tomcat web.xml
View web.xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<web-app xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
metadata-complete="true"
version="2.5">
<!-- ********************************************************************* -->
@chapmandu
chapmandu / 01-copy-lucee-server-xml.config
Created Jun 9, 2015
.ebextension copy lucee-server.xml for tomcat8
View 01-copy-lucee-server-xml.config
container_commands:
copy_lucee_server_xml:
command: "cp -f .ebextensions/lucee-server.xml /var/lib/tomcat8/webapps/ROOT/WEB-INF/lib/lucee-server/context/lucee-server.xml"
@chapmandu
chapmandu / lucee-server.xml
Created Jun 9, 2015
Empty lucee-server.xml
View lucee-server.xml
<?xml version="1.0" encoding="UTF-8"?><!--
Path placeholders:
{lucee-server}: path to the lucee server directory typical where the lucee.jar is located
{lucee-config}: same as {lucee-server} in server context and same as {lucee-web} in web context}
{temp-directory}: path to the temp directory of the current user of the system
{home-directory}: path to the home directory of the current user of the system
{web-root-directory}: path to the web root
{system-directory}: path to thesystem directory
{web-context-hash}: hash of the web context
@chapmandu
chapmandu / urlrewrite.xml
Last active Aug 29, 2015
Tuckey urlrewrite.xml config file for Lucee server
View urlrewrite.xml
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE urlrewrite PUBLIC "-//tuckey.org//DTD UrlRewrite 4.0//EN"
"http://www.tuckey.org/res/dtds/urlrewrite4.0.dtd">
<urlrewrite>
<rule>
<note>
Allow TomCat to have SES links.
</note>
<!--
If our URI ends with one of these extentions we will not perform
@chapmandu
chapmandu / UsersTest.cfc
Created Dec 9, 2012
Controller Functional Test
View UsersTest.cfc
<cfcomponent extends="wheelsMapping.Test">
<!---
# SETUP & TEARDOWN
--->
<!--- setup runs before every test --->
<cffunction name="setup">
<!--- save the orginal environment --->
<cfset loc.originalApplication = Duplicate(application)>
@chapmandu
chapmandu / simpleProperties.cfc
Created May 24, 2012
SimpleProperties Plugin
View simpleProperties.cfc
<cfcomponent output="false" mixin="model">
<cffunction name="init" returntype="any" access="public" output="false">
<cfset this.version = "1.1.7,1.1.8">
<cfreturn this />
</cffunction>
<cffunction name="simplePropertiesVersion" returntype="string" access="public" output="false">
<cfreturn "1.0" />
</cffunction>
View LessSupport.cfc
<cfcomponent output="false" mixin="controller">
<cffunction name="init" returntype="any" access="public" output="false">
<cfset this.version = "1.1.7,1.1.8">
<cfreturn this />
</cffunction>
<cffunction name="LessSupportVersion" returntype="string" access="public" output="false">
<cfreturn "1.0.1" />
</cffunction>
@chapmandu
chapmandu / wheels_view_assets.cfm
Created Apr 17, 2012
LESS support in styleSheetLinkTag
View wheels_view_assets.cfm
<cffunction name="styleSheetLinkTag" returntype="string" access="public" output="false" hint="Returns a `link` tag for a stylesheet (or several) based on the supplied arguments."
examples=
'
<!--- view code --->
<head>
<!--- Includes `stylesheets/styles.css` --->
##styleSheetLinkTag("styles")##
<!--- Includes `stylesheets/blog.css` and `stylesheets/comments.css` --->
##styleSheetLinkTag("blog,comments")##
<!--- Includes printer style sheet --->
You can’t perform that action at this time.