Skip to content

Instantly share code, notes, and snippets.

View bradparks's full-sized avatar

Brad Parks bradparks

  • Fredericton, New Brunswick, Canada
View GitHub Profile
@bradparks
bradparks / falsehoods-programming-time-list.md
Created September 2, 2022 12:18 — forked from timvisee/falsehoods-programming-time-list.md
Falsehoods programmers believe about time, in a single list

Falsehoods programmers believe about time

This is a compiled list of falsehoods programmers tend to believe about working with time.

Don't re-invent a date time library yourself. If you think you understand everything about time, you're probably doing it wrong.

Falsehoods

  • There are always 24 hours in a day.
  • February is always 28 days long.
  • Any 24-hour period will always begin and end in the same day (or week, or month).
@bradparks
bradparks / activetable.js
Created July 12, 2022 11:43 — forked from stevesouders/activetable.js
ActiveTable is a bookmarklet that makes any table sortable. It also allows you to remove columns, and it remembers the removed columns for next time. Use alt+click to UNhide all columns (and clear memory). To use it, create a bookmark called "ActiveTable" that has this URL: javascript:(function(){ var jselem=document.createElement('SCRIPT'); jse…
// ActiveTable - a bookmarklet to make tables sortable and editable
function init() {
var aHrows = getHrows();
var numHrows = aHrows.length;
var aHidden = getHiddenColumns();
ATpopup = document.createElement("div");
ATpopup.style.cssText = "position: absolute; visibility: hidden; padding: 0; font-family: Arial; background-color: rgba(255, 255, 255, 0.9); border-radius: .5em; text-align: center; box-shadow: .05em .05em .5em #00C;";
ATpopup.innerHTML = "<a href='sort' title='sort' onclick='sortColumn(); return false'><img border=0 src='http://stevesouders.com/images/sort_up_down.png' style='padding-top: 0.2em;'></a><br><a href='hide' style='color: #C00; font-family: monospace; font-size: 1.5em; text-decoration: none;' title='hide' onclick='hideColumn(); return false'>x</a>"; // TODO - use protocol-less URL for img
@bradparks
bradparks / console.py
Created March 3, 2022 19:44 — forked from j1o1h1n/console.py
This is a demo of an interactive console in a Textual user interface.
from __future__ import annotations
import string
import code
import sys
import io
from typing import Callable
from textual.app import App
from textual.widgets import Header, ScrollView
  • leave at 10:30

  • Switch

  • portable hand sanitizer

  • 5 Masks

  • wear KN95 mask and don’t take off/eat on bus so make sure he has something good to eat as it’s a long drive

  • something warm on body and feet and clothes and underwear as well as toothbrush

  • two outfits, small, so you could keep pack on bus, otherwise they put it underneath, takes longer.

  • headphones

wander
The Lab - free VR mini gameso, works on Flat screens too
nextvr - live events, like nba, etc
fitxr - group fitness
guided meditation VR or the blue
360 cities app
YouTube VR, National Geographic Explore, Ocean Rift
Spatial - meetings
Escape Rooms
Google Earth VR
@bradparks
bradparks / Docker
Created September 2, 2021 11:49 — forked from mitchwongho/Docker
Docker 'run' command to start an interactive BaSH session
# Assuming an Ubuntu Docker image
$ docker run -it <image> /bin/bash
@bradparks
bradparks / make_portable.sh
Created May 20, 2021 00:53 — forked from Birch-san/make_portable.sh
Make a macOS executable binary or .dylib portable
#!/usr/bin/env bash
# Licensed by author Alex Birch under CC BY-SA 4.0
# https://creativecommons.org/licenses/by-sa/4.0/
# Example input:
# ./make_portable.sh mycoolbinary
# where mycoolbinary is a mach-o object file
# (for example an executable binary or a .dylib)
#
@bradparks
bradparks / Dockerfile
Created April 9, 2021 00:11 — forked from jcavat/Dockerfile
docker-compose with php/mysql/phpmyadmin/apache
FROM php:7.1.2-apache
RUN docker-php-ext-install mysqli
@bradparks
bradparks / AddCustomEditorMenuItem.cs
Created February 26, 2021 01:29 — forked from Domiii/AddCustomEditorMenuItem.cs
Adds a new "Add custom Editor" MenuItem to Script files in the Unity Project view (download *.unitypackage file here: https://files.fm/u/j4r8cve5 )
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEditor;
using System.IO;
using System.Text.RegularExpressions;
@bradparks
bradparks / aws.md
Created January 15, 2021 18:18 — forked from colinvh/aws.md
AWS Region Names

Alternative naming schemes for AWS regions

Purpose

The intent is to define terse, standards-supported names for AWS regions.

Schemes