Skip to content

Instantly share code, notes, and snippets.

View rmacfie's full-sized avatar
😎

Robert Macfie rmacfie

😎
  • Stockholm, Sweden
View GitHub Profile
@rmacfie
rmacfie / server.ts
Created October 6, 2016 17:16
Convert application/octet-stream upload to ReadableStream
import * as stream from "stream";
import * as express from "express";
import * as bodyParser from "body-parser";
const app = express();
app.use(bodyParser.raw());
app.use(bodyParser.json());
app.post("/upload", (req: express.Request, res: express.Response, next: express.NextFunction) => {
# bash completion
export BASH_COMPLETION_COMPAT_DIR="/usr/local/etc/bash_completion.d"
[[ -r "/usr/local/etc/profile.d/bash_completion.sh" ]] && . "/usr/local/etc/profile.d/bash_completion.sh"
# nvm
export NVM_DIR="$HOME/.nvm"
[ -s "/usr/local/opt/nvm/nvm.sh" ] && . "/usr/local/opt/nvm/nvm.sh"
[ -s "/usr/local/opt/nvm/etc/bash_completion" ] && . "/usr/local/opt/nvm/etc/bash_completion"
@rmacfie
rmacfie / side-by-side.html
Last active May 8, 2017 16:41
side-by-side
<!DOCTYPE html>
<html>
<head>
<title>Side by Side</title>
<meta http-equiv="refresh" content="30" />
<style>
html {
box-sizing: border-box;
}
@rmacfie
rmacfie / profiles.json
Last active March 27, 2020 11:15
Windows Terminal settings
{
"$schema": "https://aka.ms/terminal-profiles-schema",
"defaultProfile": "{574e775e-4f2a-5b96-ac1e-a2962a402336}",
"profiles": {
"defaults": {
"startingDirectory": "C:\\Source",
"snapOnInput": true,
"closeOnExit": true,
"historySize": 9001,
"colorScheme": "VS Code",