Skip to content

Instantly share code, notes, and snippets.

View dcchambers's full-sized avatar
🚀
happy engineers == productive engineers

Dakota Chambers dcchambers

🚀
happy engineers == productive engineers
View GitHub Profile
@mcrumm
mcrumm / phx_sqlite_fly_launch.md
Last active January 15, 2024 07:49
Phoenix + SQLite Deployment tips

Deploying to Fly.io with SQLite

Deploying a Phoenix app to Fly.io is a breeze...is what everyone kept telling me. In fairness, I imagine the process would have been breezier had I just used postgres, but all the sqlite and litestream talk has been far too intriguing to ignore. "Wait", you say. "It is just a flat file. How much harder can it be?"

It is easy to make something harder than it should be. It is hard to take something complex and make it truly simple. flyctl launch does an amazing job at providing a simple interface to the utterly complex task of generating deployment resources, especially now that we are living in a containerd (erm, firecracker) world.

This gist is for anyone who, like me, thinks they know better than to read all of the documentation and therefore necessari

@kepano
kepano / obsidian-web-clipper.js
Last active April 18, 2024 20:47
Obsidian Web Clipper Bookmarklet to save articles and pages from the web (for Safari, Chrome, Firefox, and mobile browsers)
javascript: Promise.all([import('https://unpkg.com/turndown@6.0.0?module'), import('https://unpkg.com/@tehshrike/readability@0.2.0'), ]).then(async ([{
default: Turndown
}, {
default: Readability
}]) => {
/* Optional vault name */
const vault = "";
/* Optional folder name such as "Clippings/" */
@gullyn
gullyn / flappy.html
Last active November 28, 2023 18:23
Flappy bird in 205 bytes (improved!)
<body onload=z=c.getContext`2d`,setInterval(`c.width=W=150,Y<W&&P<Y&Y<P+E|9<p?z.fillText(S++${Y=`,9,9|z.fillRect(p`}*0,Y-=--M${Y+Y},P+E,9,W),P))):p=M=Y=S=6,p=p-6||(P=S%E,W)`,E=49) onclick=M=9><canvas id=c>
@dcchambers
dcchambers / docker-nuke-safely
Last active December 6, 2019 19:58 — forked from n3r0-ch/docker-nuke
Docker Nuke (Safely) 🐳💣- Clean up your Docker environment in a (sort of) safe way!
#!/bin/bash
#Check if user is root
if [ $UID != 0 ]; then
echo "You need to be root to use this script."
exit 1
fi
echo "docker-nuke-safely exists to do one thing; clean up your Docker environment. It's not called docker-carefully-and-nicely-spritz-up. Be careful!"
echo
@webframp
webframp / keybase.md
Created July 25, 2017 18:14
Signing git commits on github using keybase.io gpg key

Probably one of the easiest things you'll ever do with gpg

Install Keybase: https://keybase.io/download and Ensure the keybase cli is in your PATH

First get the public key

keybase pgp export | gpg --import

Next get the private key

@dcchambers
dcchambers / cli.md
Last active April 23, 2020 18:37
Commonly used Linux/Unix commands and programs one should be vaguely familiar with. Not an exhaustive list of all tools - just a list of the essentials.

File/Directory Management

  • touch
  • ls
  • ln
  • cp
  • mkdir
  • mv
  • rm
  • rmdir
  • which
@thekeenant
thekeenant / cs-resources.md
Last active December 26, 2023 17:50
My CS bookmarks.

Cheatsheets

Learning & Practice

  • Pramp: Free forever peer-to-peer technical interview practice.
  • InterviewBit: Gamified practice for typical coding interview questions.
  • Project Euler: Math/CS related challenge problems. Try them and complete them at your own pace.

FWIW: I (@rondy) am not the creator of the content shared here, which is an excerpt from Edmond Lau's book. I simply copied and pasted it from another location and saved it as a personal note, before it gained popularity on news.ycombinator.com. Unfortunately, I cannot recall the exact origin of the original source, nor was I able to find the author's name, so I am can't provide the appropriate credits.


Effective Engineer - Notes

What's an Effective Engineer?