This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
import csv | |
import sys | |
import subprocess | |
from collections import namedtuple | |
DiskTrack = namedtuple("DiskTrack", "disk track episode name filename") | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Un-scrape | |
Downloads images from the ~NEW~ section on Unslash.com and stores them for later use | |
Created by Roulx | |
Modified by midelh | |
""" | |
# I'm in python3 on this PC, | |
# so this should allow me to use my print and you can still run this in py2 | |
from __future__ import print_function | |
import json #json over csv, personal preference |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ng.directive('smGroup', ['$cacheFactory', '$log', function ($cacheFactory, $log) { | |
var cache = $cacheFactory('smGroupModelCache'); | |
function searchAndDestroy(array, target) { | |
var index, found; | |
if (!Array.isArray(array)) { | |
return false; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function () { | |
'use strict'; | |
var checkbox = (function checkBoxBuilder() { | |
var prototype = { | |
values: function () { | |
var keys = Object.keys(this); | |
var type = this; | |
return keys.filter(function (key) { | |
return type[key]; | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function(ng, undefined) { | |
ng.module('sm.directive') | |
.factory('es6Macro', [function es6Macro() { | |
// ECMAScript6 style string replacement implemented in ES5 | |
return function macro(replace, macroString) { | |
var compiled = macroString, | |
keyR = Object.keys(replace), | |
replacementR = keyR.map(function (key) { | |
return new RegExp('\\${' + key + '}', 'g'); | |
}), keyIdx, replacementCnt = replacementR.length; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
from __future__ import print_function | |
from argparse import ArgumentParser, Namespace | |
import subprocess | |
import logging | |
import sys | |
import os.path | |
try: | |
import configparser as cp |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
social/sys/classes/mvses.reports.class.php:139: LEFT JOIN product_dept pd ON t.ptype = pd.id | |
social/sys/classes/mvses.credits.class.php:238: LEFT JOIN product_dept pd ON p.department_id = pd.id | |
social/sys/func/cron.sync.system_updates.php:87: $dept = $mydb->GetOne("SELECT department FROM product_dept WHERE id={$deptid}"); | |
social/sys/era404.mvses.setup.php:155:echo "<b>====|| CREATING product_dept TABLE:<br /></b><ul>"; | |
social/sys/era404.mvses.setup.php:156: $query = "CREATE TABLE IF NOT EXISTS product_dept ( | |
social/sys/era404.mvses.setup.php:180:echo "<b>====|| POPULATING product_dept TABLE:<br /></b><ul>"; | |
social/sys/era404.mvses.setup.php:182: $query = "INSERT IGNORE INTO product_dept (id, department, item) VALUES ($did, '{$d[0]}','{$d[1]}')"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.filter('findMatches', [function() { | |
return function findMatches(arr1, arr2) { | |
// We cache because JS has some funny properties. | |
var len1, len2, i, j, matches, match; | |
// Because you're passing in strings | |
arr1 = arr1.split(' '); | |
arr2 = arr2.split(' '); | |
// Since the container will always be filled with matches | |
matches = []; | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
interface DecoratorInterface { | |
public function dectorate($value, array $options); | |
public function supports($class); | |
} | |
class InvalidDecoratorSerilizationException extends \Exception {}; | |
class DateTimeDecorator impliments DecoratorInterface { |