<script src="//jspm.io/system.js" type="text/javascript"></script>
<script src="//code.innit.io/system.config.js" type="text/javascript"></script>
<script src="//code.innit.io/zone.js" type="text/javascript"></script>
<script src="//code.innit.io/angular2/angular2.js" type="text/javascript"></script>
This file contains hidden or 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
| var data = []; | |
| $(".ti__details").each(function(i){ | |
| var artist = $(this).find(".ti__artist meta").attr("content"); | |
| var title = $(this).find(".ti__title").attr("content"); | |
| var format = artist + " - " + title; | |
| var yt = 'http://www.youtube.com/results?search_type=&search_query=' + encodeURI(artist + " " + title) + '&aq=f&oq='; | |
| var spoti = 'https://play.spotify.com/search/'+ encodeURI(artist + " " + title); | |
| var item = new Object; | |
| console.groupCollapsed(format); | |
| console.log(yt); |
This file contains hidden or 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 node | |
| // This plugin replaces text in a file with the app version from config.xml. | |
| var wwwFileToReplace = "js/build.js"; | |
| var fs = require('fs'); | |
| var path = require('path'); | |
| var rootdir = process.argv[2]; |
This file contains hidden or 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
| import {Component as _Component, Template as _Template} from 'angular2/src/core/annotations/annotations'; | |
| function makeDecorator(annotationClass) { | |
| return (options) => { | |
| return (klass) => { | |
| klass.annotations = klass.annotations || []; | |
| klass.annotations.push(new annotationClass(options)); | |
| return klass; | |
| }; | |
| }; |
This file contains hidden or 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
| #! /bin/sh | |
| # DESCRIPTION Setup wildcard domains using dnsmasq so *.doc is automatically sent to a running boot2docker vm | |
| # MAINTAINER [email protected] | |
| # See: | |
| # https://echo.co/blog/never-touch-your-local-etchosts-file-os-x-again | |
| # https://gist.github.com/r10r/5108046 | |
| # http://passingcuriosity.com/2013/dnsmasq-dev-osx/ | |
| # check for homebrew | |
| if ! command -v brew >/dev/null; then |
This file contains hidden or 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
| var https = require('https'); | |
| var util = require('util'); | |
| exports.handler = function(event, context) { | |
| console.log(JSON.stringify(event, null, 2)); | |
| console.log('From SNS:', event.Records[0].Sns.Message); | |
| var postData = { | |
| "channel": "#aws-sns", | |
| "username": "AWS SNS via Lamda :: DevQa Cloud", |
This file contains hidden or 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
| /** | |
| * RWHttp | |
| * | |
| * Base Class Used for making XHR/AJAX requests, uses the ES6 window.fetch API where available, or Github's polyfill. | |
| */ | |
| import {fetch} from './network/RWFetch'; | |
| import {RWHttpRequest} from './network/RWHttpRequest'; | |
| import {RWHttpResponse} from './network/RWHttpResponse'; | |
| import {RWHttpConfig} from './network/RWHttpConfig'; |
Update! There is now a script to do these steps for you.
These instructions will set up local-npm so that it runs as a launch daemon, meaning that it will start up whenever you log in.
First, install local-npm and pm2:
This file contains hidden or 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
| import VerEx from 'verbal-expressions'; | |
| const eventualCallIs = name => { | |
| // FOR PERF | |
| const boundCheck = node => | |
| node.type === 'Identifier' && node.name === name || | |
| node.type === 'MemberExpression' && boundCheck(node.object) || | |
| node.type === 'CallExpression' && boundCheck(node.callee) | |
| return boundCheck; |
This file contains hidden or 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
| window.onclick = () => { | |
| // You MUST create the window on the same event | |
| // tick/stack as the user-initiated event (e.g. click callback) | |
| const googleWindow = window.open(); | |
| // Do your async work | |
| fakeAjax(response => { | |
| // Change the URL of the window you created once you | |
| // know what the full URL is! | |
| googleWindow.location.replace(`https://google.com?q=${response}`); |