This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
pip3 install dollar-ref deepdiff | |
dref -i $1 $1.dref.json | |
jq .patternProperties $1.dref.json > $1.props.json | |
dref -i $2 $2.dref.json | |
jq .patternProperties $2.dref.json > $2.props.json | |
deep diff $1.props.json $2.props.json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
from bs4 import BeautifulSoup | |
import requests | |
import sys | |
from urllib.parse import urljoin | |
from pprint import pprint | |
from pathlib import Path | |
def usage(): | |
print('Usage: getonce.py [application url]') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
import time | |
import Quartz | |
def get_displays(): | |
err, activeDisplays, _ = Quartz.CGGetActiveDisplayList(6, None, None); | |
if err != Quartz.kCGErrorSuccess: | |
raise Exception(err) | |
return activeDisplays |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# License: MIT | |
# Copyright (c) David D. Dorfman 2022 | |
""" | |
Cache function arguments from callables on first invocation | |
""" | |
from functools import partial, wraps | |
from typing import Any, Callable, Optional, ParamSpec, TypeVar | |
P = ParamSpec('P') | |
R = TypeVar('R') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -e | |
git clone https://github.com/wting/autojump.git | |
cd autojump | |
./install.py |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set hlsearch | |
set number | |
set nowrap | |
set timeoutlen=50 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
import os | |
import time | |
import signal | |
st = time.time() | |
N = 1000000 | |
n = 0 | |
signal.signal(signal.SIGCHLD, signal.SIG_IGN) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# Copyright (c) 2021 David Dorfman | |
# This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License. | |
# To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-nd/4.0/. | |
# | |
import os | |
import sys | |
import appdirs | |
from collections import defaultdict | |
from datetime import datetime, timedelta |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
""" | |
"PYSTONE" Benchmark Program | |
Version: Python/1.1 (corresponds to C/1.1 plus 2 Pystone fixes) | |
Author: Reinhold P. Weicker, CACM Vol 27, No 10, 10/84 pg. 1013. | |
Translated from ADA to C by Rick Richardson. | |
Every method to preserve ADA-likeness has been used, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git b/Graphics/Rendering/Cairo/Internal/Surfaces/Win32.chs a/Graphics/Rendering/Cairo/Internal/Surfaces/Win32.chs | |
new file mode 100644 | |
index 0000000..be6de2f | |
--- /dev/null | |
+++ a/Graphics/Rendering/Cairo/Internal/Surfaces/Win32.chs | |
@@ -0,0 +1,30 @@ | |
+{-# LANGUAGE CPP #-} | |
+----------------------------------------------------------------------------- | |
+-- | | |
+-- Module : Graphics.Rendering.Cairo.Internal.Surfaces.Win32 |
NewerOlder