Skip to content

Instantly share code, notes, and snippets.

View kossnocorp's full-sized avatar
Shipping

Sasha Koss kossnocorp

Shipping
View GitHub Profile
def back_or_home_path
referrer = controller.respond_to?(:request) && controller.request.env['HTTP_REFERER']
local_referrer = referrer && URI.parse(referrer).host == controller.request.host
if referrer && local_referrer
referrer
else
root_path
end
end
describe 'TargetClass', ->
beforeEach ->
@domState = $('*')
afterEach ->
$('*').each (i, el) =>
$(el).remove() if @domState.filter(el).length is 0
# ...

Keybase proof

I hereby claim:

  • I am kossnocorp on github.
  • I am kossnocorp (https://keybase.io/kossnocorp) on keybase.
  • I have a public key whose fingerprint is B6CF C68E A2E2 3590 869C 09AF 66BF 23C4 E7A3 86D9

To claim this, I am signing this object:

describe('true', function() {
it('must be true', function() {
expect(true).to.be.true;
});
it('must not be true', function() {
expect(true).to.not.be.false;
});
});
This file has been truncated, but you can view the full file.
window.commitsOrigin = {
"url": "https://api.github.com/repos/facebook/immutable-js/compare/b82b6191fb18395d22ff516adf06a61124ffe6d6...HEAD",
"html_url": "https://github.com/facebook/immutable-js/compare/b82b6191fb18395d22ff516adf06a61124ffe6d6...HEAD",
"permalink_url": "https://github.com/facebook/immutable-js/compare/facebook:b82b619...facebook:a1608fc",
"diff_url": "https://github.com/facebook/immutable-js/compare/b82b6191fb18395d22ff516adf06a61124ffe6d6...HEAD.diff",
"patch_url": "https://github.com/facebook/immutable-js/compare/b82b6191fb18395d22ff516adf06a61124ffe6d6...HEAD.patch",
"base_commit": {
"sha": "b82b6191fb18395d22ff516adf06a61124ffe6d6",
"commit": {
"author": {
min-screen(end_at)
@media screen and (min-width: end_at)
{block}
screen(start_at)
@media screen and (max-width: start_at)
{block}
screen-1280()
+screen(1323px)

Intallation

wget https://gist.github.com/kossnocorp/ece8c568a08de6fbff95/raw/b041a023d0114ef11ba9c2b568510c37f4c19918/TODO.js
npm install date-fns string-fns chalk commander
brew install ag

Usage

var csp = require('js-csp');
var Github = require('./github');
var GoogleMaps = require('./google_maps');
var TEAM = process.env.GITHUB_TEAM;
csp.go(function*() {
var team = yield csp.take(Github.getTeamMembers(TEAM));
for (var i = 0; i < team.length; i++) {
var noLocationStr = function(origin) {
return !!origin.get('location_str');
};
var withStatus = function(foreignKey, statuses, origin) {
return origin
.set('status', statuses.find(s => s.get(foreignKey) == origin.get('id')));
};
var withLocation = function(locations, locationStr, origin) {