Skip to content

Instantly share code, notes, and snippets.

@teodorlu
teodorlu / AAA-README.md
Created July 2, 2022 19:44 — forked from jackrusher/AAA-README.md
Clojure + FUSE

Meld

A minimal example of creating a (mostly) working FUSE filesystem using Clojure. NOTE: I have only tested this with OSX, and it assumes you have already installed libfuse.

Trying it out

Create an empty directory at /tmp/meld to serve as your mount point, put these files in a directory called meld, then:

@teodorlu
teodorlu / setup-db-commands.py
Created December 21, 2019 20:57
Quickly get started with a new database + user
#!/usr/bin/env python3
from pprint import pprint
from random import randint
import sys
# Database name required
def print_err(*args, **kwargs):
print(*args, file=sys.stderr, **kwargs)
@teodorlu
teodorlu / Lib.hs
Created August 17, 2019 11:35
Create your own operator in Haskell
module Lib where
someFunc :: IO ()
someFunc = putStrLn "someFunc"
data Expr a =
Number a
| Plus (Expr a) (Expr a)
deriving (Show, Read)
Happy Birthday to You
Happy Birthday to You
Happy Birthday Dear Kevin
Happy Birthday to You.
From good friends and true,
From old friends and new,
May good luck go with you,
And happiness too.
@teodorlu
teodorlu / pydoc.py
Created May 23, 2017 08:58
pydoc.py from Abaqus' Python 2.7 distribution
#!/usr/bin/env python
# -*- coding: latin-1 -*-
"""Generate Python documentation in HTML or text for interactive use.
In the Python interpreter, do "from pydoc import help" to provide online
help. Calling help(thing) on a Python object documents the object.
Or, at the shell command line outside of Python:
Run "pydoc <name>" to show documentation on something. <name> may be
import Distribution.Simple
main = defaultMain
-- Kjør på turtle
function main()
-- Hva sier pheripherals? Hvilken side er modemet på?
rednet.open("left")
while true do
sender, message = rednet.receive(99999)
print("Message from " .. sender .. " received: ")
print(message)
shell.run(unpack(message))
@teodorlu
teodorlu / erik-aa.md
Last active August 29, 2015 14:07
Navnebytte: hvordan å finne et godt navn

@Erik:

La meg dele opp aktuelle bedrifter for hybrider i grupper.

(1) Kjente bedrifter

Focus veit knallgodt hvem vi er og hva vi er gode for. Antall hybrider i Focus sier sitt. Det samme gjelder KBe, og jeg vil tippe Norkart og NOIS. Jeg kan ikke tenke meg at et navnebytte vil ødelegge forholdet til noen av nevnte bedrifter. Disse vil vite hvem vi er uansett om vi bytter navn.

(2) Delvis kjente bedrifter

Andre bedrifter veit ikke like godt hvem vi er. Ta f.eks. 4Subsea, som har invitert oss på maskin-bedpreser. De har kanskje hørt navnet, men har ikke noe direkte forhold til I&IKT, og har heller ikke årlig kontakt med bedriftsrepsesentanter fra BedKom. Her kommer vi til å skape forvirring.