Skip to content

Instantly share code, notes, and snippets.

View inoperable's full-sized avatar
💣
RTFM || GTFO

inoperable inoperable

💣
RTFM || GTFO
  • REDACTED
  • REDACTED
  • 21:12 (UTC +02:00)
View GitHub Profile
@inoperable
inoperable / .eslintrc.js
Created March 22, 2017 00:04 — forked from nkbt/.eslintrc.js
Strict ESLint config for React, ES6 (based on Airbnb Code style)
{
"env": {
"browser": true,
"node": true,
"es6": true
},
"plugins": ["react"],
"ecmaFeatures": {
@inoperable
inoperable / defaults-export.zsh
Last active November 30, 2024 06:09
export defaults for all domains in macOS into separate .plist files for editing and importing, files are written into $HOME/defaults
#!/usr/bin/env zsh
function exportDefaults {
local outdir="$HOME/defaults"
local outdirApple="$outdir/apple"
local outdirUser="$outdir/user"
local outdirGlobal="$outdir/global"
local filesdone=0
local filecount=0
local filestotal=0
@inoperable
inoperable / grabahref.js
Created March 6, 2017 10:49
insta lodash/jquery a href grab to clipboard
// copy / paste for semi-insta $/_ into devtools-console
fetch('https://raw.githubusercontent.com/lodash/lodash/4.17.4/dist/lodash.js').then(response => {
return response.text()
}).then((text) => eval(text));
fetch('https://code.jquery.com/jquery-3.1.1.js').then(response => {
return response.text()
}).then((text) => eval(text));
@inoperable
inoperable / business-models.md
Created November 28, 2016 11:54 — forked from ndarville/business-models.md
Business models based on the compiled list at http://news.ycombinator.com/item?id=4924647. I find the link very hard to browse, so I made a simple version in Markdown instead.

Business Models

Advertising

Models Examples
Display ads Yahoo!
Search ads Google
@inoperable
inoperable / TrueColour.md
Created November 5, 2016 13:37 — forked from XVilka/TrueColour.md
True Colour (16 million colours) support in various terminal applications and terminals

Colours in terminal

It's a common confusion about terminal colours... Actually we have this:

  • plain ascii
  • ansi escape codes (16 colour codes with bold/italic and background)
  • 256 colour palette (216 colours + 16 ansi + 24 gray) (colors are 24bit)
  • 24bit true colour ("888" colours (aka 16 milion))
printf "\x1b[${bg};2;${red};${green};${blue}m\n"
@inoperable
inoperable / web-servers.md
Created October 17, 2016 17:29 — forked from willurd/web-servers.md
Big list of http static server one-liners

Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.

Discussion on reddit.

Python 2.x

$ python -m SimpleHTTPServer 8000
@inoperable
inoperable / gulpfile.js
Created October 20, 2015 04:33
gulp tasks
var fs = require('fs'),
path = require('path'),
gulp = require('gulp'),
gutil = require('gulp-util'),
es = require('event-stream'),
concat = require('gulp-concat'),
runSequence = require('gulp-run-sequence'),
templateCache = require('gulp-angular-templatecache'),
minifyHtml = require('gulp-minify-html'),
ngmin = require('gulp-ngmin'),
@inoperable
inoperable / gulpfile.js
Created October 19, 2015 14:44 — forked from danharper/gulpfile.js
New ES6 project with Babel, Browserify & Gulp
var gulp = require('gulp');
var sourcemaps = require('gulp-sourcemaps');
var source = require('vinyl-source-stream');
var buffer = require('vinyl-buffer');
var browserify = require('browserify');
var watchify = require('watchify');
var babel = require('babelify');
function compile(watch) {
var bundler = watchify(browserify('./src/index.js', { debug: true }).transform(babel));
@inoperable
inoperable / rails_resources.md
Created October 10, 2015 00:08 — forked from jookyboi/rails_resources.md
Rails-related Gems and guides to accelerate your web project.

Gems

  • Bundler - Bundler maintains a consistent environment for ruby applications. It tracks an application's code and the rubygems it needs to run, so that an application will always have the exact gems (and versions) that it needs to run.
  • rabl - General ruby templating with json, bson, xml, plist and msgpack support
  • Thin - Very fast and lightweight Ruby web server
  • Unicorn - Unicorn is an HTTP server for Rack applications designed to only serve fast clients on low-latency, high-bandwidth connections and take advantage of features in Unix/Unix-like kernels.
  • SimpleCov - SimpleCov is a code coverage analysis tool for Ruby 1.9.
  • Zeus - Zeus preloads your Rails app so that your normal development tasks such as console, server, generate, and specs/tests take less than one second.
  • [factory_girl](h