Skip to content

Instantly share code, notes, and snippets.

View kmein's full-sized avatar
🦀
computering hard

Kierán Meinhardt kmein

🦀
computering hard
View GitHub Profile
@mightybyte
mightybyte / haskell-language-extensions.md
Last active August 31, 2023 07:50
A Taxonomy of Haskell Language Extensions

Haskell Language Extension Taxonomy

Caveat: It's just personal opinion, and was written to be a bit provocative and encourage discussion . It is also something that is constantly evolving. Some of the main criteria I used in constructing this taxonomy are age, how widely used it us, and how well understood it is by the average Haskell programmer. These things will change over time.

Aso, this is focused on appropriateness for use in commercial production code bases. If you are not thinking about commercial use with a team of multiple

@joshbuchea
joshbuchea / semantic-commit-messages.md
Last active May 23, 2024 22:24
Semantic Commit Messages

Semantic Commit Messages

See how a minor change to your commit message style can make you a better programmer.

Format: <type>(<scope>): <subject>

<scope> is optional

Example

@bembu
bembu / telegram_irc_bridge.py
Last active September 20, 2020 20:29
A script that acts as a bridge between IRC and Telegram.
"""
A script that acts as a messaging bridge between Telegram and IRC.
Works in Python 3.x
Installation:
1. pip install pydle
2. go create a Telegram bot by talking to BotFather (https://telegram.me/botfather)
3. create a telegram group, and send a curl to:
curl -s -X POST "https://api.telegram.org/bot<BOT_TOKEN>w/getUpdates"
4. get the group_id from the response
@magarcia
magarcia / Yumml.md
Last active September 3, 2022 02:42
YumML - Yet Another Recipe Metadata Language
layout title description date tags
page
YumML, use YumML, not XML
Yet Another Recipe Metadata Language - you know, for food.
2011-09-21
food yumml

I won't beat around the bush - existing metadata formats for food recipes suck. Alone that would be my typical bold/arrogant claim, so I present my findings on five different formats (RecipeML, Recipe Exchange Markup Language, CookML and RecipeBook XML) to backup that statement, and then my proposed format. There was a sixth format I was looking into - MealMaster - but the recipe structure doesn't seem to be defined anywhere and as far as I know the only program to use it is MealMaster itself.

@logrusorgru
logrusorgru / mysql.sql
Last active January 16, 2024 07:01
SQL: uniqueness, automatic created_at, updated_at refresh + soft delete. SQLite, PostgreSQL, MySQL
-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
-- --
-- mysql --
-- --
-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
--
-- mysql <http://sqlfiddle.com/#!9/91afb5/2>
-- note: sqlfiddle is very stupid
__ __ _ ___ _ _
\ \ / /_ _| |__ / __| |_ __ ___ _(_)_ _ __ _
\ V / _` | / / \__ \ ' \/ _` \ V / | ' \/ _` |
|_|\__,_|_\_\ |___/_||_\__,_|\_/|_|_||_\__, |
|___/ YAK SHAVING LTD
═══════════════
Company Number: 09522289
73 Douglas Buildings
Marshalsea Road
@nylki
nylki / char-rnn recipes.md
Last active March 16, 2024 15:13
char-rnn cooking recipes

do androids dream of cooking?

The following recipes are sampled from a trained neural net. You can find the repo to train your own neural net here: https://github.com/karpathy/char-rnn Thanks to Andrej Karpathy for the great code! It's really easy to setup.

The recipes I used for training the char-rnn are from a recipe collection called ffts.com And here is the actual zipped data (uncompressed ~35 MB) I used for training. The ZIP is also archived @ archive.org in case the original links becomes invalid in the future.

@4z3
4z3 / nix-haddock-index.sh
Last active September 4, 2019 06:54
nix-haddock-index.sh
#! /bin/sh
set -euf
# TODO NIX_GHC=$(type -P ghc) NIX_GHC_DOCDIR=$(dirname $(dirname $(type -P ghc)))/share/doc/ghc/html
# if unset: this is for e.g. emse-hdsb
main() {
pkg=$(dirname $(dirname $NIX_GHC))
@mboersma
mboersma / yaml2json
Last active July 31, 2023 12:34
YAML to JSON one-liner
python3 -c 'import sys, yaml, json; y=yaml.safe_load(sys.stdin.read()); print(json.dumps(y))'