Skip to content

Instantly share code, notes, and snippets.

@jelsas
jelsas / .screenrc
Created March 10, 2011 13:33
.screenrc file that adds ctrl-arrow window switching, a nice status & a few other things
# the following two lines give a two-line status, with the current window highlighted
#hardstatus alwayslastline "%= %3n %t%? [%h]%? %="
#caption always "%= %-w%L>%{= BW}%n*%t%{-}%52<%+w %L="
hardstatus alwayslastline
hardstatus string '%{= kG}[%{G}%H%? %1`%?%{g}][%= %{= kw}%-w%{+b yk} %n*%t%?(%u)%? %{-}%+w %=%{g}][%{B}%m/%d %{W}%C%A%{g}]'
defscrollback 3000
@nhusher
nhusher / 1.rendering-header.js
Last active March 26, 2017 04:40
Rendering the CC7 header in React
var React = require('react'),
utils = require('../util/react-dom-utils'),
html = utils.html,
make = utils.make;
var Chevron = make(function (p) {
var points = [
"M13.0490629,0.160143149",
"C13.2439546,-0.0533810496",
"13.6018161,-0.0533810496",
@paf31
paf31 / 24days.md
Last active August 8, 2023 05:53
24 Days of PureScript

This blog post series has moved here.

You might also be interested in the 2016 version.

# Hello, and welcome to makefile basics.
#
# You will learn why `make` is so great, and why, despite its "weird" syntax,
# it is actually a highly expressive, efficient, and powerful way to build
# programs.
#
# Once you're done here, go to
# http://www.gnu.org/software/make/manual/make.html
# to learn SOOOO much more.
@tdd
tdd / angular-just-say-no.md
Last active November 18, 2022 20:47
Angular: Just Say No

Angular: Just say no

A collection of articles by AngularJS veterans, sometimes even core committers, that explain in detail what's wrong with Angular 1.x, how Angular 2 isn't the future, and why you should avoid the entire thing at all costs unless you want to spend the next few years in hell.

Reason for this: I'm getting tired of having to explain to everyone, chief of which all the indiscriminate Google Kool-Aid™ drinkers, why I have never believed in Angular, why I think it'll publicly fail pretty soon now (a couple years), and why it's a dead end IMO. This gist serves as a quick target I can point people to in order not to have to parrot / compile the core of the articles below everytime. Their compounded reading pretty much captures 99% of my view on the topic.

This page is accessible through http://bit.ly/angular-just-say-no and http://bit.ly/angularjustsayno, btw.

@TylerK
TylerK / index.jsx
Created July 6, 2015 18:29
Multi Column Photo component
import React from 'react';
import Store from './photos.store'
import Photo from './photos.photo'
import PhotoGrid from './photos.grid'
export default React.createClass({
displayName: 'PhotosIndex',
componentWillMount() {
this.setState({
@quephird
quephird / Pi.purs
Last active September 3, 2015 22:39
Solution to exercise in PureScript by Example book to estimate pi
module Pi where
import Control.Monad.Eff (Eff(..), forE)
import Control.Monad.Eff.Random (RANDOM(..), random)
import Control.Monad.ST (ST(..), modifySTRef, newSTRef, readSTRef)
import Data.Array ((:), filter, length)
import Data.Int (toNumber)
import Data.Tuple (Tuple(..))
import Prelude (($), (<=), (+), (*), (/), bind, return, unit)
@jamiebuilds
jamiebuilds / gulpfile.js
Created October 5, 2015 20:45
Example multi-file gulp setup
export lint from './task-lint';
export test from './task-test';
export build from './task-build';
export dev from './task-dev';
export default dev;
@sgnn7
sgnn7 / enable_mongo.sh
Created December 22, 2015 23:06
Mongodb 3.2 on Ubuntu 15.10
echo '[Unit]
Description=High-performance, schema-free document-oriented database
After=syslog.target network.target
[Service]
User=mongodb
Group=mongodb
ExecStart=/usr/bin/mongod -f /etc/mongod.conf
[Install]

Redux Chaos Monkey

This is a proof of concept which allows you to replay system events in a random order each time to make sure your UI can tolerate variable states.

I'm not sure if this is worthy of its on open source project with additional features like changing play back time, whitelisting/blacklisting actions etc but figured I'd put this out there to see if it piques anyones interest.

See a video of this in action here: [https://www.youtube.com/watch?v=wkoukONfwmA](Video on YouTube).