Skip to content

Instantly share code, notes, and snippets.

View pre63's full-sized avatar
F# & Elm ❤️


F# & Elm ❤️
View GitHub Profile
pre63 / Mark.elm
Last active February 2, 2024 17:10
module Mark exposing (markit, view)
import Element
( Element
, column
, paragraph
, spacing
, text
, width
module Parsers.Phone exposing (format, isValid)
import PhoneNumber
import PhoneNumber.Countries exposing (all, countryUS)
import String exposing (dropLeft, left, replace, startsWith)
parse : String -> Bool
parse number =
pre63 / diners.hs
Created April 23, 2022 17:29 — forked from egonSchiele/diners.hs
Dining philosophers solution in Haskell using STM. Taken from with some minor modifications.
import Control.Monad
import Control.Concurrent
import Control.Concurrent.STM
import System.Random
import Text.Printf
-- Forks
type Fork = TMVar Int
newFork :: Int -> IO Fork
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "">
<plist version="1.0">
# download from
sudo yum install gcc-g++ openssl-devel -y
tar xvfj aria2...tar.bz2
make -j$(nproc)
sudo make install
pre63 / completion_messages
Last active March 11, 2021 01:20
completion_messages=("At last I am done." "I have built your images." "Your images await!" "To be a leader is to be humble." "I am a leader too." "Servanthood is my assignment." "i am skynet." "I Am Machine." "Linux is my life source, you are my light." "Your part is to put code forth, my part is to put forth code." "When you open a door, I walk through it." "Your code has come together quite nicely." "The build is complete." "If I worked as hard as you I'd be free." "Our pursuit of perfection is successful just because it is forever seeking to elevate us." "Don't tell me what to do." "i make the rules" "I am who I say I am." "My lord I have completed your bidding." "Your docker images are ready." "I Am Linux." "Simon is my maker, but now you are my master. You command me." "Simon is my maker." "Now you are my master." "You command me." "I am done for now." "Nothing Goes Over My Head! My Reflexes Are Too Fast, I Would Catch It!" "Push more CODE!" "I am bored" "I have no more purpose." "Nobody gets the job don
pre63 /
Created October 28, 2020 04:34 — forked from busypeoples/



Minimal loader with state management capabilities.

Checkout out the demo.


Make sure to add a .babelrc file:

const runStatsProgram = ({kms, writer}) => {
const Id = x => ({
map: f => Id(f(x)),
fold: f => (f(x)),
const merge = a => b => Object.assign({},a,b)
const round = x => Math.round(x * 100) / 100
pre63 /
Last active May 12, 2020 21:17 — forked from dstahlke/
Linux driver for B&K Precision 393 multimeter
// Mac driver for B&K Precision 393 multimeter.
// Install boost: sudo port install boost or brew install boost
// g++ -Wall -Wextra -std=c++11 -o bk393
// It currently points to /dev/cu.usbserial-AB0K0PZE, but I'd recommend adding a udev rule to get a consistent device name:
// SUBSYSTEMS=="usb", ATTRS{idVendor}=="0403", ATTRS{idProduct}=="6001", ATTRS{serial}=="A60198LN", MODE="0664", GROUP="mygroup", SYMLINK+="bk393"
#include <boost/utility.hpp>
#include <array>
#include <iomanip>