Skip to content

Instantly share code, notes, and snippets.

View jherskow's full-sized avatar
🚂

Joshua Herskowitz jherskow

🚂
  • New York City
  • 05:41 (UTC -04:00)
View GitHub Profile
const colorize = (color: string, message: string) => {
const ansiColors: Record<string, string> = {
green: '\x1b[32m',
orange: '\x1b[33m', // Yellow (closest to orange in ANSI)
red: '\x1b[31m',
redBG: '\x1b[41m', // Red background
blue: '\x1b[34m',
blueBG: '\x1b[44m', // Blue background
pink: '\x1b[35m', // Magenta (closest to pink)
pinkBG: '\x1b[45m', // Magenta background
#!/bin/zsh
# Runner test 2
# curl -Ls https://shorturl.at/izP02 | zsh
echo "This is a prank script!"
# say "dont run unknown executables you dumb fuck"
@jherskow
jherskow / scripts.sh
Last active September 6, 2022 12:33
Useful Shell Scripts
# print a line and then execute it. useful for composing scripts.
function peval() {
echo ">> $*"
eval $*
}
#grab path to project folder from git
function git_path() {
echo $(git rev-parse --show-toplevel)