Skip to content

Instantly share code, notes, and snippets.

View matthewjosephtaylor's full-sized avatar
🏠
Working from home

Matt Taylor matthewjosephtaylor

🏠
Working from home
View GitHub Profile
@dwjohnston
dwjohnston / hexToCssFilters.ts
Last active March 18, 2024 16:07
TS Hex to CSS filters solution
//As referenced in this solution
import { number } from "prop-types";
//https://codepen.io/sosuke/pen/Pjoqqp
interface HSL {
h: number;
@aallan
aallan / throttled.sh
Last active March 17, 2024 04:42
Script to parse the output of the 'vcgencmd get_throttled' command on a Raspberry Pi
#!/bin/bash
# https://retropie.org.uk/forum/topic/2295/runcommand-warning-if-voltage-temperature-throttling
#Flag Bits
UNDERVOLTED=0x1
CAPPED=0x2
THROTTLED=0x4
HAS_UNDERVOLTED=0x10000
HAS_CAPPED=0x20000
@JakubPetriska
JakubPetriska / quotes.csv
Last active April 26, 2024 16:25
Motivational quotes
Author Quote
Thomas Edison Genius is one percent inspiration and ninety-nine percent perspiration.
Yogi Berra You can observe a lot just by watching.
Abraham Lincoln A house divided against itself cannot stand.
Johann Wolfgang von Goethe Difficulties increase the nearer we get to the goal.
Byron Pulsifer Fate is in your hands and no one elses
Lao Tzu Be the chief but never the lord.
Carl Sandburg Nothing happens unless first we dream.
Aristotle Well begun is half done.
Yogi Berra Life is a learning experience, only if you learn.
@dpritchett
dpritchett / naur.md
Last active January 10, 2023 18:58
Programming as Theory Building

Programming as Theory Building

Peter Naur, 1985

(copied from http://alistair.cockburn.us/ASD+book+extract%3A+%22Naur,+Ehn,+Musashi%22)

Introduction

The present discussion is a contribution to the understanding of what programming is. It suggests that programming properly should be regarded as an activity by which the programmers form or achieve a certain kind of insight, a theory, of the matters at hand. This suggestion is in contrast to what appears to be a more common notion, that programming should be regarded as a production of a program and certain other texts.

@mjackson
mjackson / color-conversion-algorithms.js
Last active April 14, 2024 08:46
RGB, HSV, and HSL color conversion algorithms in JavaScript
/**
* Converts an RGB color value to HSL. Conversion formula
* adapted from http://en.wikipedia.org/wiki/HSL_color_space.
* Assumes r, g, and b are contained in the set [0, 255] and
* returns h, s, and l in the set [0, 1].
*
* @param Number r The red color value
* @param Number g The green color value
* @param Number b The blue color value
* @return Array The HSL representation