Skip to content

Instantly share code, notes, and snippets.

View FractalHQ's full-sized avatar
💭
🔬

Braden Wiggins FractalHQ

💭
🔬
View GitHub Profile
@FractalHQ
FractalHQ / quish.sh
Last active May 25, 2023 00:15
Simple batch video processing.
#!/bin/zsh
e() {
echo "$1"
}
fmt() {
if [ -t 1 ]; then
printf "%b\n" "$1"
else
e "$1"
@FractalHQ
FractalHQ / .zshrc
Created March 21, 2023 16:44
My `.zshrc` (MacOS)
# Fig pre block. Keep at the top of this file.
[[ -f "$HOME/.fig/shell/zshrc.pre.zsh" ]] && builtin source "$HOME/.fig/shell/zshrc.pre.zsh"
DEFAULT_USER=$USER
# Enable Powerlevel10k instant prompt. Should stay close to the top of ~/.zshrc.
if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]; then
source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh"
fi
# Path to your oh-my-zsh installation.
@FractalHQ
FractalHQ / mdsvex-icon.svg
Created October 9, 2021 23:03
Penguin Emoji SVG
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@FractalHQ
FractalHQ / mdsvex.settings.jsonc
Last active July 28, 2021 17:03
Mdsvex Icon Instructioins
// Add this to global user settings
{
"material-icon-theme.files.associations": {
"mdsvex.config.js": "../../../../.vscode/extensions/icons/mdsvex"
}
}
// Add this svg to "~/.vs-code/extensions/icons/mdsvex.svg"
<svg xmlns="http://www.w3.org/2000/svg" width="500" height="500" viewBox="0 0 500 500">
@FractalHQ
FractalHQ / asyncLocalStorageStore.ts
Created July 13, 2021 20:01
asyncLocalStorageStore for Sveltekit
import { writable } from 'svelte/store';
import { browser } from '$app/env';
const setAsync = async (key: string, value: any): Promise<void> => {
return Promise.resolve().then(() => {
typeof value != 'string'
? localStorage.setItem(key, JSON.stringify(value))
: localStorage.setItem(key, value);
});
}
@FractalHQ
FractalHQ / localStorageStore.js
Last active March 23, 2023 21:41
Async LocalStorage Svelte Store
import { writable } from 'svelte/store';
const client = typeof window !== "undefined";
const asyncLocalStorage = {
setItem: function (key, value) {
return Promise.resolve().then(function () {
typeof value != 'string'
? localStorage.setItem(key, JSON.stringify(value))
: localStorage.setItem(key, value);
@FractalHQ
FractalHQ / co-prism.css
Created November 9, 2020 04:20
CP Prism Theme
/* Generated with http://k88hudson.github.io/syntax-highlighting-theme-generator/www */
/* http://k88hudson.github.io/react-markdocs */
/**
* @author k88hudson
*
* Based on prism.js default theme for JavaScript, CSS and HTML
* Based on dabblet (http://dabblet.com)
* @author Lea Verou
*/
/*********************************************************
@FractalHQ
FractalHQ / CO_Logo_Spin_2
Created October 15, 2020 11:31
CO_Logo_Spin_2
"{\"v\":\"5.5.7\",\"meta\":{\"g\":\"LottieFiles AE 0.1.20\",\"a\":\"Braden Wiggins\",\"k\":\"\",\"d\":\"CO_Logo_Spin_1.2\",\"tc\":\"\"},\"fr\":60,\"ip\":0,\"op\":60,\"w\":2400,\"h\":1000,\"nm\":\"Spin-1\",\"ddd\":0,\"assets\":[],\"layers\":[{\"ddd\":0,\"ind\":1,\"ty\":4,\"nm\":\"MotionPath Arrow_ Black 2\",\"sr\":1,\"ks\":{\"o\":{\"a\":0,\"k\":100,\"ix\":11},\"r\":{\"a\":0,\"k\":0,\"ix\":10},\"p\":{\"a\":0,\"k\":[1369.962,499.164,0],\"ix\":2},\"a\":{\"a\":0,\"k\":[873.962,362.664,0],\"ix\":1},\"s\":{\"a\":0,\"k\":[100,100,100],\"ix\":6}},\"ao\":0,\"shapes\":[{\"ty\":\"gr\",\"it\":[{\"ind\":0,\"ty\":\"sh\",\"ix\":1,\"ks\":{\"a\":0,\"k\":{\"i\":[[0,-200.294],[200.294,0],[66.52,78.058],[0,0],[102.785,0],[0,-199.747],[-199.747,0],[-65.916,69.568],[0,0],[-99.8,0]],\"o\":[[0,200.294],[-110.595,0],[0,0],[-65.846,-68.843],[-199.747,0],[0,199.747],[103.403,0],[0,0],[65.575,-65.228],[200.294,0]],\"v\":[[1747.923,362.664],[1385.259,725.329],[1109.111,597.766],[623.075,111.719],[361.673,0],[0,361.673],[361.673,723.347],[
@FractalHQ
FractalHQ / co-logo-spin-1.json
Last active September 24, 2020 02:01
co-logo-spin-1
{"v":"5.5.7","meta":{"g":"LottieFiles AE 0.1.20","a":"Braden Wiggins","k":"","d":"COLogo Spin 1","tc":""},"fr":60,"ip":0,"op":60,"w":2400,"h":1000,"nm":"Spin-1","ddd":0,"assets":[],"layers":[{"ddd":0,"ind":1,"ty":4,"nm":"MotionPath Arrow_ Black 2","hd":true,"sr":1,"ks":{"o":{"a":0,"k":100,"ix":11},"r":{"a":0,"k":0,"ix":10},"p":{"a":0,"k":[1369.962,499.164,0],"ix":2},"a":{"a":0,"k":[873.962,362.664,0],"ix":1},"s":{"a":0,"k":[100,100,100],"ix":6}},"ao":0,"shapes":[{"ty":"gr","it":[{"ind":0,"ty":"sh","ix":1,"ks":{"a":0,"k":{"i":[[0,-200.294],[200.294,0],[66.52,78.058],[0,0],[102.785,0],[0,-199.747],[-199.747,0],[-65.916,69.568],[0,0],[-99.8,0]],"o":[[0,200.294],[-110.595,0],[0,0],[-65.846,-68.843],[-199.747,0],[0,199.747],[103.403,0],[0,0],[65.575,-65.228],[200.294,0]],"v":[[1747.923,362.664],[1385.259,725.329],[1109.111,597.766],[623.075,111.719],[361.673,0],[0,361.673],[361.673,723.347],[624.258,610.386],[1129.501,105.539],[1385.259,0]],"c":true},"ix":2},"nm":"Path 1","mn":"ADBE Vector Shape - Group","hd":fals
@FractalHQ
FractalHQ / cologo_spin_1.json
Last active September 24, 2020 00:19
COLogo_Spin_1
"{\"v\":\"5.5.7\",\"meta\":{\"g\":\"LottieFiles AE 0.1.20\",\"a\":\"Braden Wiggins\",\"k\":\"\",\"d\":\"COLogo Spin 1\",\"tc\":\"\"},\"fr\":60,\"ip\":0,\"op\":60,\"w\":2400,\"h\":1000,\"nm\":\"Spin-1\",\"ddd\":0,\"assets\":[],\"layers\":[{\"ddd\":0,\"ind\":1,\"ty\":4,\"nm\":\"MotionPath Arrow_ Black 2\",\"hd\":true,\"sr\":1,\"ks\":{\"o\":{\"a\":0,\"k\":100,\"ix\":11},\"r\":{\"a\":0,\"k\":0,\"ix\":10},\"p\":{\"a\":0,\"k\":[1369.962,499.164,0],\"ix\":2},\"a\":{\"a\":0,\"k\":[873.962,362.664,0],\"ix\":1},\"s\":{\"a\":0,\"k\":[100,100,100],\"ix\":6}},\"ao\":0,\"shapes\":[{\"ty\":\"gr\",\"it\":[{\"ind\":0,\"ty\":\"sh\",\"ix\":1,\"ks\":{\"a\":0,\"k\":{\"i\":[[0,-200.294],[200.294,0],[66.52,78.058],[0,0],[102.785,0],[0,-199.747],[-199.747,0],[-65.916,69.568],[0,0],[-99.8,0]],\"o\":[[0,200.294],[-110.595,0],[0,0],[-65.846,-68.843],[-199.747,0],[0,199.747],[103.403,0],[0,0],[65.575,-65.228],[200.294,0]],\"v\":[[1747.923,362.664],[1385.259,725.329],[1109.111,597.766],[623.075,111.719],[361.673,0],[0,361.673],[361.673,7