Skip to content

Instantly share code, notes, and snippets.

Nix on macOS Catalina

I'm writing this gist for my own records but it might help someone else too.

Installing Nix

Support for Catalina has improved a lot since the update was first rolled out.

Note: See the NixOS manual for discussion of the --darwin-use-unencrypted-nix-store-volume option.

@longle255
longle255 / README.md
Created February 21, 2020 18:24 — forked from mrbar42/README.md
bash scripts to create VOD HLS stream with ffmpeg almighty (tested on Linux and OS X)

running:

bash create-vod-hls.sh beach.mkv

will produce:

    beach/
      |- playlist.m3u8
 |- 360p.m3u8
@longle255
longle255 / Google Image Resize Proxy
Created February 21, 2020 13:40 — forked from nblenke/Google Image Resize Proxy
Use Google's Image caching/optimization proxy to resize an image
(function () {
var img = document.createElement('img');
path = encodeURIComponent('https://s3.amazonaws.com/llama0/burningfiremonkey.gif'),
width = 600,
refresh = 2592000;
img.src = 'https://images1-focus-opensocial.googleusercontent.com/gadgets/proxy?url=' + path + '&resize_w=' + width + '&container=focus&refresh=' + refresh;
document.body.appendChild(img);
}());
@longle255
longle255 / google-img-resize.mdown
Created February 21, 2020 13:40
Google’s authentication-less on-the-fly image resizing service

Google's authentication-less on-the-fly image resizing service

I found it while poking around the Google+ HTML. Jotting down some notes felt like a good idea, so here goes. If you know more about this API, let me know, please!

(Word of warning: I spent ~30 minutes on both my experimentation and this here write-up, so it might not be the most thought-provoking, brilliant thing you read today.)

#!/bin/bash
###############
# setup-node.sh
#
# Long Le <lel@usi.ch>
# October 29h, 2019
#
# Purpose: install package dependencies for libramcast, set up system config
###############
0x1bf2CC355AAe659288670F21A11bCAF2E7D456b5
@longle255
longle255 / osx-10.9-setup.md
Created September 24, 2016 14:27 — forked from kevinelliott/osx-10.9-setup.md
Clean Install – Mac OS X 10.9 Mavericks

Mac OS X 10.9 Mavericks

Custom recipe to get OS X 10.9 Mavericks running from scratch, setup applications and developer environment. I use this gist to keep track of the important software and steps required to have a functioning system after a semi-annual fresh install.

Install Software

The software selected is software that is "tried and true" --- software I need after any fresh install. I often install other software not listed here, but is handled in a case-by-case basis.

Install from App Store

@longle255
longle255 / ngrok-selfhosting-setup.md
Last active February 14, 2019 10:52 — forked from lyoshenka/ngrok-selfhosting-setup.md
How to setup Ngrok with a self-signed SSL cert

Intro

The plan is to create a pair of executables (ngrok and ngrokd) that are connected with a self-signed SSL cert. Since the client and server executables are paired, you won't be able to use any other ngrok to connect to this ngrokd, and vice versa.

DNS

Add two DNS records: one for the base domain and one for the wildcard domain. For example, if your base domain is domain.com, you'll need a record for that and for *.domain.com.

Different Operating Systems

@longle255
longle255 / gist:18c38a230bc64ff51bd5
Created February 11, 2016 09:58
Install Ubuntu's MongoDB 2.4.6 armhf packages on a current Debian Sid (tested with Cubieboard)
sudo aptitude install libboost1.53-dev libpcrecpp0 libboost-filesystem1.53-dev libboost-program-options1.53-dev libboost-system1.53-dev libboost-thread1.53-dev libpcap0.8 libsnappy1 libv8-3.14.5
wget http://launchpadlibrarian.net/149424649/mongodb-clients_2.4.6-0ubuntu5_armhf.deb
sudo dpkg -i mongodb-clients_2.4.6-0ubuntu5_armhf.deb
wget http://launchpadlibrarian.net/149424646/mongodb-server_2.4.6-0ubuntu5_armhf.deb
sudo dpkg -i mongodb-server_2.4.6-0ubuntu5_armhf.deb
@longle255
longle255 / designer.html
Created August 13, 2014 17:08
designer
<link rel="import" href="../topeka-elements/category-images.html">
<link rel="import" href="../core-icon/core-icon.html">
<link rel="import" href="../core-icons/core-icons.html">
<link rel="import" href="../core-icons/av-icons.html">
<link rel="import" href="../paper-fab/paper-fab.html">
<link rel="import" href="../topeka-elements/category-icons.html">
<polymer-element name="my-element">
<template>