Skip to content

Instantly share code, notes, and snippets.

View SaintPeter's full-sized avatar

Rex Schrader SaintPeter

View GitHub Profile
@SaintPeter
SaintPeter / directory_traverse.js
Created August 17, 2018 01:58
Node.js Simple Depth First Directory Traverse
fs = require('fs');
// Initialize the stack with the path on the command line
let stack = [
{
path: process.argv[2],
level: 1
}
];
@SaintPeter
SaintPeter / angular-fullstack-redirect.js
Last active August 29, 2015 14:27 — forked from dcoffey3296/angular-fullstack-redirect.js
Authentication redirect for angular-fullstack yeoman generator
// The Yeoman angular-fullstack generator allows for authentication to be required
// when a user goes to a given route. To enable this behavior, add
authenticate: true
// to your /client/app/<routename>/<routename>.js file, in the .when routing block.
// like this:
angular.module('meanApp')
.config(function ($routeProvider) {
$routeProvider
.when('/', {
templateUrl: 'app/main/main.html',