Skip to content

Instantly share code, notes, and snippets.

View stringparser's full-sized avatar
🏠
Working from home

Javier Carrillo Milla stringparser

🏠
Working from home
View GitHub Profile
//
// Regular Expression for URL validation
//
// Author: Diego Perini
// Updated: 2010/12/05
// License: MIT
//
// Copyright (c) 2010-2013 Diego Perini (http://www.iport.it)
//
// Permission is hereby granted, free of charge, to any person

Keybase proof

I hereby claim:

  • I am stringparser on github.
  • I am stringparser (https://keybase.io/stringparser) on keybase.
  • I have a public key whose fingerprint is 1801 9FA4 E47C 2CB8 A543 EBA3 7202 1D35 C4F2 9BCB

To claim this, I am signing this object:

Disclaimer: This is an unofficial post by a random person from the community. I am not an official representative of io.js. Want to ask a question? open an issue on the node-forward discussions repo

io.js - what you need to know

io-logo-substack

  • io is a fork of node v0.12 (the next stable version of node.js, currently unreleased)
  • io.js will be totally compatible with node.js
  • the people who created io.js are node core contributors who have different ideas on how to run the project
  • it is not a zero-sum game. many core contributors will help maintain both node.js and io.js
@stringparser
stringparser / composer.js
Created April 1, 2015 15:11
composing async functions
var store = {}; // lets say here we store things to map a string to a function
function Stack(){} // so we can identify composed functions
Stack.prototype.onHandle = function(next){
// measure times or other things
}
Stack.prototype.onHandleError = function(err){
if(err instanceof Error){ throw err; }
//
// README:
// - Listens for PUSH events
// - Fetches the ref pushed via the given remote
// - Sets the repositories HEAD to latest ref
// - Checks out the new HEAD (--force)
// - Install dependencies from package.json
// - Calls `npm run reload` (My app uses this)
// - Calls `nginx -s reload` (My app also uses this)
//

2015-01-29 Unofficial Relay FAQ

Compilation of questions and answers about Relay from React.js Conf.

Disclaimer: I work on Relay at Facebook. Relay is a complex system on which we're iterating aggressively. I'll do my best here to provide accurate, useful answers, but the details are subject to change. I may also be wrong. Feedback and additional questions are welcome.

What is Relay?

Relay is a new framework from Facebook that provides data-fetching functionality for React applications. It was announced at React.js Conf (January 2015).

/*! normalize.css v1.0.1 | MIT License | git.io/normalize */
article,aside,details,figcaption,figure,footer,header,hgroup,nav,section,summary{display:block}
audio,canvas,video{display:inline-block;*display:inline;*zoom:1}
audio:not([controls]){display:none;height:0}
[hidden]{display:none}
html{font-size:100%;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%}
html,button,input,select,textarea{font-family:sans-serif}
body{margin:0}
a:focus{outline:thin dotted}
a:active,a:hover{outline:0}
@stringparser
stringparser / texsvg.hs
Last active August 29, 2015 14:25 — forked from lierdakil/texsvg.hs
Pandoc filter to convert math to inline svg using latex and dvisvgm
import Text.Pandoc.JSON
import System.Directory
import System.FilePath ((</>))
import qualified Data.Hash.MD5 as MD5
import System.IO.Temp
import System.Process
import Control.Monad (unless)
main :: IO ()
main = toJSONFilter mathToSvg
var _ = require('underscore');
var Backbone = require('backbone');
var cheerio = require('cheerio');
var request = require('request');
Backbone.ajax = function(options) {
options.json = true;
return request(options, function(error, result) {
if (error) {
@stringparser
stringparser / oneToCloneThemAll.sh
Created July 31, 2015 16:59
Clone all private repos of an organization
curl -u <token>:x-oauth-basic -s https://api.github.com/orgs/<orgName>/repos | node -e '
var repos="";
process.stdin.resume();
process.stdin.setEncoding("utf8");
process.stdin.on("data", function(data){
repos += data;
});
process.stdin.on("end", function(){
JSON.parse(repos).forEach(function(repo){
require("child_process").spawn("git", ["clone", repo.html_url], {stdio: "inherit"});