Skip to content

Instantly share code, notes, and snippets.

View michael-erasmus's full-sized avatar

Michael Erasmus michael-erasmus

View GitHub Profile
@michael-erasmus
michael-erasmus / runtests.py
Last active April 13, 2016 07:03 — forked from jiffyclub/runtests.py
An IPython %runtests magic that does some very basic test function discovery, running, and reporting within IPython.
from IPython.core.magic import register_line_magic
import pandas as pd
@register_line_magic
def runtests(line):
"""
The %runtests magic searches your IPython namespace for functions
with names that begin with 'test'. It will attempt to run these
functions (calling them with no arguments), and report whether they
pass, fail (raise an AssertionError), or error (raise any other
/*
This example uses Scala. Please see the MLlib documentation for a Java example.
Try running this code in the Spark shell. It may produce different topics each time (since LDA includes some randomization), but it should give topics similar to those listed above.
This example is paired with a blog post on LDA in Spark: http://databricks.com/blog
Spark: http://spark.apache.org/
*/
import scala.collection.mutable

CodeIgniter Style Guide

This is collectively being called a style guide, however it serves as a standard to enforce a stricter and more enforced methodology in how programming should be done in CodeIgniter.

Why

CodeIgniter is powerful. CodeIgniter is hugely popular. It's popular because it's easy. It's easy because there are many ways to accomplish a task.

CodeIgniter is terrible for the exact reasons which make it powerful. You can too easily place code in a confusing place, or not separate concerns, thus creating programming challenges down the line. It's noob-friendly, which means it's inherently easy to make noob mistakes.

This document serves to restrict coding practices within CodeIgniter with the purpose of making an application with more class (pun without-a-doubt, most-strongly intended).