Skip to content

Instantly share code, notes, and snippets.

View citizen428's full-sized avatar

Michael Kohl citizen428

View GitHub Profile
@wiseman
wiseman / example.md
Last active August 21, 2024 02:55
Get store hours from images
$ python hours.py image.jpg
{
  "day_hours": [
    {
      "day": "Mon - Fri",
      "hours": "7 AM - 5 PM"
    },
    {
 "day": "Saturday",
// ==UserScript==
// @name TweetXer
// @namespace https://github.com/lucahammer/tweetXer/
// @version 0.9.3
// @description Delete all your Tweets for free.
// @author Luca,dbort,pReya,Micolithe,STrRedWolf
// @license NoHarm-draft
// @match https://x.com/*
// @match https://mobile.x.com/*
// @match https://twitter.com/*
@kconner
kconner / macOS Internals.md
Last active March 11, 2025 07:16
macOS Internals

macOS Internals

Understand your Mac and iPhone more deeply by tracing the evolution of Mac OS X from prelease to Swift. John Siracusa delivers the details.

Starting Points

How to use this gist

You've got two main options:

OpenBSD logo     Rails logo     Falcon logo


Choose OpenBSD for your Unix needs. OpenBSD -- the world's simplest and most secure Unix-like OS. A safe alternatve to the frequent vulnerabilities and overengineering of Linux and related software (NGiNX & Apache (httpd-asiabsdcon2015.pdf), OpenSSL, iptables/nftables, systemd, BIND, Postfix, Docker etc.)

OpenBSD -- the cleanest kernel, the cleanest userland and the cleanest config

@raiph
raiph / .md
Last active February 10, 2025 21:01
Raku's "core"

Then mathematical neatness became a goal and led to pruning some features from the core of the language.

— John McCarthy, History of Lisp

If you prefer programming languages with a tidy and tiny core, you're in for a treat. This article drills down to the singleton primitive at the heart of Raku's metamodel ("model of a model") of a model of computation ("how units of computations, memories, and communications are organized")1.

The reason I've written this article

It began with u/faiface's reddit post/thread "I'm impressed with Raku"2. One of their sentences in particular stood out for me:

@Lysxia
Lysxia / Binary.hs
Created February 26, 2020 20:33
Binary pattern-matching on bytestrings
{-# LANGUAGE
ScopedTypeVariables,
ViewPatterns,
PatternSynonyms #-}
import Data.Bits (Bits, shift)
import Data.Word
import Data.ByteString (ByteString)
import qualified Data.ByteString as BS
import qualified Data.ByteString.Char8 as B8
@swlaschin
swlaschin / effective-fsharp.md
Last active October 20, 2024 12:47
Effective F#, tips and tricks

Architecture

  • Use Onion architecture

    • Dependencies go inwards. That is, the Core domain doesn't know about outside layers
  • Use pipeline model to implement workflows/use-cases/stories

    • Business logic makes decisions
    • IO does storage with minimal logic
    • Keep Business logic and IO separate
  • Keep IO at edges

@justdoit0823
justdoit0823 / golang_essence.md
Last active August 22, 2018 07:08
Golang essence.

Code organization

Overview

  • Go programmers typically keep all their Go code in a single workspace.
  • A workspace contains many version control repositories (managed by Git, for example).
  • Each repository contains one or more packages.
@nickytonline
nickytonline / my-mac-setup.sh
Last active December 17, 2024 16:19
Mac Setup Scripts
#!/bin/sh
# More Mac setup at https://mac.iamdeveloper.com
# Log file
timestamp=$(date +%s)
logFile="./my-mac-setup-$timestamp.log"
# if true is passed in, things will reinstall
reinstall=$1
@IvanIvanoff
IvanIvanoff / pre-commit
Last active October 23, 2022 07:48
pre-commit hook for checking mix formatting
#!/bin/bash
cd `git rev-parse --show-toplevel`
echo "Running pre-commit hook: Check elixir formatting with mix format"
mix format --check-formatted
if [ $? == 1 ]; then
echo "mix format --check-formatted found formatting issues."
exit 1
fi