This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"metadata": { | |
"name": "", | |
"signature": "sha256:9e533461c3971d0ca543d09b07e7430683b57758b8768a2c2718424791da3e54" | |
}, | |
"nbformat": 3, | |
"nbformat_minor": 0, | |
"worksheets": [ | |
{ | |
"cells": [ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy | |
import scipy | |
import matplotlib.pyplot as pyplot | |
def decibel(lin): | |
"""Convert amplitude to decibel. | |
We might later need power to decibel...""" | |
return 20*numpy.log10(norm(lin)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
provide-module color-mark %{ | |
declare-option int color_mark_index 0 | |
set-face global ColorMark0 rgb:FF7F00+rb | |
set-face global ColorMark1 rgb:0095FF+rb | |
set-face global ColorMark2 rgb:FF00AA+rb | |
set-face global ColorMark3 rgb:6AFF00+rb | |
set-face global ColorMark4 rgb:00EAFF+rb | |
set-face global ColorMark5 rgb:AA00FF+rb | |
set-face global ColorMark6 rgb:8F2323+rb | |
set-face global ColorMark7 rgb:23628F+rb |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/// I used Mono.Cecil 0.9.5 | |
/// This code is proof of concept quality! | |
using System; | |
using Mono.Cecil; | |
using System.Collections.Generic; | |
using Mono.Cecil.Cil; | |
using System.IO; | |
using Mono.Collections.Generic; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ldapdb = collections.namedtuple("namespace", ['person', 'group', 'share', 'maillist']) | |
ldapdb.person = ldap_to_pandas(ldap.search(filter="(&(objectClass=univentionPerson))", base=common.ucs_access.base_dn())) | |
ldapdb.group = ldap_to_pandas(ldap.search(filter="(&(objectClass=univentionGroup))", base=common.ucs_access.base_dn())) | |
ldapdb.share = ldap_to_pandas(ldap.search(filter="(&(objectClass=univentionShare))", base=common.ucs_access.base_dn())) | |
ldapdb.maillist = ldap_to_pandas(ldap.search(filter="(&(objectClass=univentionMailList))", base=common.ucs_access.base_dn())) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
if [ -z "$1" ]; then | |
aplay -L | grep -v "^ " | cut -d ':' -f 2 | uniq | sort | uniq | |
exit 1 | |
fi | |
cat <<EOF > "$HOME/.asoundrc" | |
pcm.!default { | |
type asym |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$> cat run-server.sh | |
#!/bin/sh | |
# Copyright (c) 2012-2015 Kaarle Ritvanen | |
# See LICENSE file for license details | |
export AUGEAS_LENS_LIB=augeas | |
if [ $(basename $0) = run-server.sh ]; then | |
export LUA_PATH="./?.lua;./?/init.lua;;" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$> cat run-server.sh | |
#!/bin/sh | |
# Copyright (c) 2012-2015 Kaarle Ritvanen | |
# See LICENSE file for license details | |
export AUGEAS_LENS_LIB=augeas | |
if [ $(basename $0) = run-server.sh ]; then | |
export LUA_PATH="./?.lua;./?/init.lua;;" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
qemu-system-x86_64 | |
-m 512M | |
-serial stdio | |
-monitor null | |
-kernel {S.kernel} | |
-initrd {S.initramfs} | |
-drive file=root.squashfs,if=virtio,format=raw | |
--append "root=/dev/vda console=ttyS0" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import json | |
import smtplib | |
import subprocess | |
import sys | |
import time | |
from email.message import EmailMessage | |
import toml | |
TO = "i@k.l" |
NewerOlder