Skip to content

Instantly share code, notes, and snippets.

Laurence Roberts lsjroberts

Block or report user

Report or block lsjroberts

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View hyper-terminal
module.exports = {
config: {
// default font size in pixels for all tabs
fontSize: 14,
// font family with optional fallbacks
fontFamily: '"Meslo LG M DZ", "Fira Sans Code", Menlo, "DejaVu Sans Mono", Consolas, "Lucida Console", monospace',
// terminal cursor background color and opacity (hex, rgb, hsl, hsv, hwb or cmyk)
cursorColor: 'rgba(248,28,229,0.8)',
@lsjroberts
lsjroberts / route-helpers.js
Last active Jul 26, 2017
Dynamic loading helpers for React Router
View route-helpers.js
const loadRoute = (next) =>
(module) =>
next(null, module.default);
const loadRoutes = (next) =>
(modules) =>
next(null, modules.map(module => module.default));
const loadRouteComponent = (importer) =>
(location, next) =>
View keybase.md

Keybase proof

I hereby claim:

  • I am lsjroberts on github.
  • I am lsjroberts (https://keybase.io/lsjroberts) on keybase.
  • I have a public key whose fingerprint is EF95 5587 0E88 0044 FC4C 0690 2B11 CC51 EA87 8ECA

To claim this, I am signing this object:

@lsjroberts
lsjroberts / github-templates.js
Last active Aug 29, 2015
Templates for github pull requests and issues
View github-templates.js
javascript:(
function() {
var e=document.getElementById('pull_request_body');
if (e) {
e.value += '#### What does this do?\n\n';
e.value += '#### How should this be manually tested?\n\n';
e.value += '#### Related PRs / Issues / Resources?\n\n';
e.value += '#### Anything else to add? (Screenshots, background context, etc)\n\n';
}
}
@lsjroberts
lsjroberts / gulpfile.js
Last active Jan 24, 2019
Gulp styles & scripts build and watcher
View gulpfile.js
/**
* Install:
* $ npm install gulp gulp-minify-css gulp-autoprefixer gulp-ruby-sass gulp-coffee gulp-uglify gulp-concat gulp-rimraf gulp-notify
*/
var gulp = require('gulp');
// styles
var minifycss = require('gulp-minify-css');
var autoprefixer = require('gulp-autoprefixer');
@lsjroberts
lsjroberts / hover-diamonds.htm
Created Oct 23, 2013
gelatindesign.co.uk redesign ideas
View hover-diamonds.htm
<!DOCTYPE html>
<html>
<head>
<style>
.diamonds {
padding: 100px;
}
.diamond {
float: left;
@lsjroberts
lsjroberts / test.php
Last active Dec 26, 2015
PHP __toString() bubble test
View test.php
<?php
class Foo {
public $bar;
public function __construct()
{
$this->bar = new Bar;
}
@lsjroberts
lsjroberts / branch.sh
Last active Dec 23, 2015
Git directory commands
View branch.sh
clear
dir=$(pwd)
for i in `find $dir -type d -maxdepth 1`; do
if [ $i != $dir ]
then
echo "\n\033[33mChecking $i\033[0m"
cd $i
git branch -v --no-abbrev | grep '*'
cd ../
fi
@lsjroberts
lsjroberts / pr.sh
Created Sep 5, 2013
Create pull request on existing issue from HEAD
View pr.sh
issue= head=HEAD base=master
while getopts i:h:b: opt; do
case $opt in
i)
issue=$OPTARG
;;
h)
head=$OPTARG
;;
You can’t perform that action at this time.