Skip to content

Instantly share code, notes, and snippets.

View yannicklamprecht's full-sized avatar
🏠
Working from home

Yannick Lamprecht yannicklamprecht

🏠
Working from home
  • Germany, Frankfurt
  • 17:06 (UTC +02:00)
View GitHub Profile
@piscisaureus
piscisaureus / pr.md
Created August 13, 2012 16:12
Checkout github pull requests locally

Locate the section for your github remote in the .git/config file. It looks like this:

[remote "origin"]
	fetch = +refs/heads/*:refs/remotes/origin/*
	url = git@github.com:joyent/node.git

Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/* to this section. Obviously, change the github url to match your project's URL. It ends up looking like this:

@puppe
puppe / absender.lco
Last active July 30, 2023 20:14
Deutsche Briefvorlage für LaTeX (scrlttr2) (ACHTUNG: Aktualisierte Version jetzt unter https://codeberg.org/puppe/german-latex-letter-template/)
\ProvidesFile{absender.lco}
\KOMAoptions{%
% fromemail=true, % Email wird im Briefkopf angezeigt
% fromphone=true, % Telefonnumer wird im Briefkopf angezeigt
% fromfax=true, % Faxnummer wird im Briefkopf angezeit
% fromurl=true, % URL wird im Briefkopf angezeigt
% fromlogo=true, % Logo wird im Briefkopf angezeigt
% subject=titled, % Druckt "Betrifft: " vor dem Betreff
locfield=wide, % Breite Absenderergänzung (location)
@rogeriopvl
rogeriopvl / gist:5009416
Last active May 30, 2023 21:24
Shell function to play RTMP streaming on OSX with VLC and rtmpdump (add to your .bashrc or .zshrc)
function rtmp_open() {
rtmpdump -r $1 --quiet | /Applications/VLC.app/Contents/MacOS/VLC fd://0 --playlist-autostart
}
@Byteflux
Byteflux / uuidconvert.py
Last active August 29, 2015 13:59
python uuidconvert.py <worldpath>
import sys
import os
import math
import urllib2
import json
import time
import shutil
import uuid
from nbt import nbt # pip install nbt
@xavriley
xavriley / README.md
Last active December 30, 2023 12:17
Original NES Mario Theme for Sonic Pi

Making Chiptune Music using Sonic Pi v2.0

Warning: this might not work on a RaspberryPi yet

I was curious about making retro gaming sounds using Sonic Pi. A couple of months and a lot of Googling later, here's the original Mario Bros theme as it was heard on the NES console.

I'm (just about) old enough to remember rushing home from school to play this game at Philip Boucher's house, sitting cross-legged in front of the TV till my feet got pins and needles. Working out how to recreate it for Sonic Pi was a lot of fun!

Getting the sounds of the NES chip

@dnozay
dnozay / README.md
Last active July 4, 2024 15:06
Collection of useful stuff for interacting with gitlab.

Reset root/admin password

Lost the root/admin password? You can reset it using the command-line. Recipe adapted from gitlab issue #308.

# start the console
sudo gitlab-rails console
@danreedy
danreedy / gist:a0f0aa1ec2eb275c55a2
Created April 16, 2015 14:39
Frozen - Let it Go - Sonic Pi
# Let it Go - Pi Version
use_bpm 34
use_synth :pretty_bell
quaver = 0.125 #Eight note
crotchet = 0.25 #Quarter note
minim = 0.5 #Half note
semibreve = 1 #Whole note
in_thread(name: :rh) {rightHand}
@wires
wires / my-service
Created October 19, 2015 10:47
minimal init.d script
#!/bin/sh
### BEGIN INIT INFO
# Provides: <NAME>
# Required-Start: $local_fs $network $named $time $syslog
# Required-Stop: $local_fs $network $named $time $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Description: <DESCRIPTION>
### END INIT INFO
@thisismitch
thisismitch / corridors_of_code.rb
Created November 18, 2015 05:36
Sonic Pi Songs
# Chrono Trigger Soundtrack - Corridors of Time
# plug this into http://sonic-pi.net/
# still needs synth pads
# global config
use_bpm 112
def play_legato_note(note_value, duration)
release_duration = duration
@mikehearn
mikehearn / KotlinDuckTyping.kt
Created December 18, 2015 13:46
Kotlin duck typing / type classing fiddle
class A {
fun shout() = println("go team A!")
}
class B {
fun shout() = println("go team B!")
}
interface Shoutable {
fun shout()