Skip to content

Instantly share code, notes, and snippets.

View ZacharyJacobCollins's full-sized avatar
☁️
head in the clouds

Zachary Collins ZacharyJacobCollins

☁️
head in the clouds
View GitHub Profile
@ZacharyJacobCollins
ZacharyJacobCollins / foo.log
Created June 24, 2018 03:39 — forked from ibeex/foo.log
Flask logging example
A warning occurred (42 apples)
An error occurred
@ZacharyJacobCollins
ZacharyJacobCollins / observable-from-stream.js
Created December 29, 2016 22:07
ES7 Observables + WHATWG Streams
// ES7 Observables + WHATWG Streams
//
// https://github.com/jhusain/asyncgenerator
// https://github.com/whatwg/streams
//
// Continuation from file:
// https://github.com/jhusain/asyncgenerator/blob/master/src/observable.js
Observable.fromStream = function(readable) {
return new Observable(function(generator) {
@ZacharyJacobCollins
ZacharyJacobCollins / Gulpfile.js
Created October 19, 2016 19:42 — forked from wrouesnel/Gulpfile.js
webpack, react, golang self-contained gulpfile
var path = require('path');
var gulp = require('gulp');
var run = require('gulp-run');
var gutil = require('gulp-util');
var minimist = require('minimist');
var options = minimist(process.argv.slice(2), {
string: 'env',
@ZacharyJacobCollins
ZacharyJacobCollins / laravel-ums.markdown
Created July 11, 2016 00:20 — forked from anchetaWern/laravel-ums.markdown
Building a User Management System in Laravel

There's no shortage of good resources for learning laravel. So instead of the usual introductory tutorial were just gonna learn Laravel by building a project from scratch and that's gonna be a User Management System.

I don't know if my definition of a User Management System is correct but here's my idea of what's it's capable of doing:

  • Register Roles
  • Register Users
  • Update Users
@ZacharyJacobCollins
ZacharyJacobCollins / Excel.php
Created June 30, 2016 15:48 — forked from barryvdh/Excel.php
Simple php-excel class to load an Excel file into an array (using Laravel json/array interface, but you don't have to use that). Don't forget to require https://packagist.org/packages/phpoffice/phpexcel or https://packagist.org/packages/codeplex/phpexcel
<?php
use Illuminate\Support\Contracts\ArrayableInterface;
use Illuminate\Support\Contracts\JsonableInterface;
class Excel implements ArrayableInterface, JsonableInterface{
protected $objPHPExcel;
public function __construct($file){
if($file instanceof \SplFileInfo){
$filename = $file->getRealPath();
@ZacharyJacobCollins
ZacharyJacobCollins / Class file
Created June 30, 2016 15:46 — forked from samatsav/Class file
Convert PHP arrays to XLS
<?php
/*
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
@ZacharyJacobCollins
ZacharyJacobCollins / goth_auth.go
Created March 17, 2016 21:30 — forked from paked/goth_auth.go
Basic OAuth with goth in golang.
package main
import (
"flag"
"fmt"
"net/http"
"github.com/gorilla/mux"
"github.com/markbates/goth"
"github.com/markbates/goth/gothic"
@ZacharyJacobCollins
ZacharyJacobCollins / basic-list-functions.sml
Created January 31, 2016 19:31 — forked from edalorzo/basic-list-functions.sml
Learning SML - Basic List Functions
(* Returns the head of a list. *)
fun head(xs) =
case xs of
[] => raise List.Empty
| (x::_) => x
(* Returns the tail of a list. *)
fun tail(xs) =
case xs of
[] => raise List.Empty