Skip to content

Instantly share code, notes, and snippets.

View mattatcha's full-sized avatar

Matt Aitchison mattatcha

View GitHub Profile
#!/bin/bash
/Applications/Filebot.app/Contents/MacOS/filebot -script fn:amc --output "/Volumes/DataOne/Media" --log-file "/Volumes/DataOne/amc.log" --action test --conflict override -non-strict --def artwork=n "ut_dir=$TR_TORRENT_DIR/$TR_TORRENT_NAME" "ut_kind=multi" "ut_title=$TR_TORRENT_NAME"
App.config(function ($stateProvider) {
$stateProvider
.state('app.classes', {
url: '/classes',
abstract: true,
template: '<ui-view/>'
})
.state('app.classes.list', {
url: '',
templateUrl: 'modules/classes/partials/list.html'
filebot -script fn:amc --output "/Volumes/DataOne/Media" --log-file amc.log --action test -non-strict "/Volumes/DataOne/CompletedOld/"
  • App
    • scripts
      • core
        • actions
        • components
        • constants
        • dispatcher
        • stores
      • pages/views
set encoding=utf-8
set nocompatible " be iMproved, required
filetype off " required
set number
let mapleader = ","
set history=100
" Store a bunch of undo history
set undolevels=400
package util
import (
"crypto/rand"
"fmt"
)
type UUID [16]byte
// create a new uuid v4
var Fluxxor = require('fluxxor');
var request = require('superagent');
var AuthStore = Fluxxor.createStore({
actions: {
"LOGIN_AUTH": "onLoginAuth",
},
initialize: function() {
this.currentUser = {};
// Create a token for the user after we verified their password.
// TODO: Store this in a db? This would be helpful if we would like to invalidate a login.
func (a *User) CreateToken() (string, error) {
token := jwt.New(jwt.GetSigningMethod("HS256"))
token.Claims["Id"] = a.Id
token.Claims["Email"] = a.Email
token.Claims["exp"] = time.Now().Add(time.Hour * 72).Unix()
// TODO: Move this to a config file.
@mattatcha
mattatcha / Test
Last active August 29, 2015 14:02
➜ v8-go-test node nodetest.js
hasownproperty x 20,284,333 ops/sec ±1.61% (85 runs sampled)
undefined x 162,378,112 ops/sec ±29.83% (47 runs sampled)
Fastest is undefined
➜ v8-go-test go run main.go
test
hasownproperty x 14,973,628 ops/sec ?0.68% (67 runs sampled)
undefined x 449,704,141 ops/sec ?0.56% (69 runs sampled)
Fastest is undefined
➜ v8-go-test
var gulp = require('gulp');
var path = require('path');
var source = require('vinyl-source-stream');
var browserify = require('browserify');
var reactify = require('reactify');
var watchify = require('watchify');
var util = require('gulp-util')
var less = require('gulp-less');
var clean = require('gulp-clean');
var plumber = require('gulp-plumber');