Skip to content

Instantly share code, notes, and snippets.

/**
* Sinon.JS 1.17.3, 2016/01/27
*
* @author Christian Johansen (christian@cjohansen.no)
* @author Contributors: https://github.com/cjohansen/Sinon.JS/blob/master/AUTHORS
*
* (The BSD License)
*
* Copyright (c) 2010-2014, Christian Johansen, christian@cjohansen.no
* All rights reserved.
@indolering
indolering / https-setup.md
Last active March 14, 2023 23:40
Shell script to generate TLS certificates for local development (.test, .example, etc)
@indolering
indolering / phoronix-av1-debug.md
Created January 28, 2023 02:36
phoronix-av1-debug
anon@anon $ phoronix-test-suite % phoronix-test-suite debug-benchmark aom-av1

    Evaluating External Test Dependencies ..................................................................................................................................................

Phoronix Test Suite v10.8.4

    Installed:     pts/aom-av1-3.5.0

@indolering
indolering / Re: Wikipedia
Last active September 24, 2021 06:10
Authorization for relicensing posithub.org list of Posit implementations.
Zach,
This is a great idea, thanks! I hope this makes it a survey that can be edited and maintained by Wikipedia editors… or does it have to be a perfect replica of what is on posithub.org? If it can be maintained by Wikipedia, I can replace that part of posithub.org with a pointer to the Wikipedia site. I am very short on manpower for maintaining posithub.org, and a lot is happening with new posit implementations.
As you suggest: https://posithub.org/docs/PDS/PositEffortsSurvey.html is CC0, CC BY-SA 3.0.
Thanks,
John Gustafson
> On Jun 6, 2021, at 12:16 PM, Zach Lym <zachlym@indolering.com> wrote:
@indolering
indolering / WASI-Case-Folding.md
Created October 21, 2020 04:51
Proposal for Unicode case-folding of WASI filenames.

I apologize for the wall of text, there are a lot of concerns raised in the WASI case-senstivity ticket and I wanted to explain how everything works without just pointing to dense specs and code.

Case-insensitivity is important because it is required by end users: Windows, OS X, and Android all enforce some level of case-insensitivity. As a practical matter, this means Linux developers must manually enforce case-insensitivity. And despite much wailing and gnashing of teeth, even Linux has recently added support for case-insensitivity on a per-directory basis. Distros that care about usability will eventually adopt case-insensitivity, even if it is just for the home directories.

WASI’s current proposal trades Unix’s opaque bytes mo

@indolering
indolering / transmission-vpn-launcher.applescript
Last active September 21, 2019 13:42
Uses Private Internet Access REST API to set which port Transmission listens on, binds all Transmission traffic to the tun0 (typically OpenVPN) network interface, and then opens Transmission.
set user to "USERNAME"
set pass to "PASSWORD"
--set token automatically based on macaddress
set macAddHash to do shell script "/sbin/ifconfig en0 | /usr/bin/awk '/ether / {print $2}' | /usr/bin/tr -d ':' | md5 "
try
set vpn_ip to do shell script "ifconfig tun0 | grep inet | awk '{print $2}'"
--hack: must delete property before writing it but first run 'defaults delete' fails
{
"users": {
"root": {
"configs": {
"ajenti.plugins.notepad.notepad.Notepad": "{\"bookmarks\": []}",
"ajenti.plugins.fm.fm.FileManager": "{\"root\": \"/\"}",
"ajenti.plugins.terminal.main.Terminals": "{\"shell\": \"sh -c $SHELL || sh\"}",
"ajenti.plugins.dashboard.dash.Dash": "{\"widgets\": [{\"index\": 0, \"config\": null, \"container\": \"0\", \"class\": \"ajenti.plugins.dashboard.welcome.WelcomeWidget\"}]}"
},
"password": "password",
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Error Illustration</title>
<script defer>
'use strict';
if(window && !window.ACMESessionID){
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Error Illustration</title>
<script defer>
'use strict';
const env = { //Some global values usually found in window or global...
@indolering
indolering / error-illustration.html
Created September 19, 2017 08:14
Illustration of error handling in ES6
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Error Illustration</title>
<script defer>
'use strict';
class CustomError extends Error {}