Skip to content

Instantly share code, notes, and snippets.

View teemow's full-sized avatar

Timo Derstappen teemow

View GitHub Profile
@teemow
teemow / fetch_subtitles.sh
Last active May 14, 2023 18:03
fetch youtube playlist with title, description and subtitles of each video and train gpt with the information
#!/bin/bash
set -eu
FOLDER=$1
PLAYLIST=$2
rm -f playlist.txt
mkdir -p $FOLDER
yt-dlp --flat-playlist -i --print-to-file url playlist.txt $PLAYLIST
@teemow
teemow / sign-intel-ucode.hook
Created October 2, 2019 15:23
pacman hooks for kernel signing
[Trigger]
Type = Package
Operation = Install
Operation = Upgrade
Target = intel-ucode
[Action]
Description = Sign the intel ucode for secure boot
Depends = sbsigntools
When = PostTransaction
#include <ESP8266WiFi.h>
#include <ESP8266httpUpdate.h>
#include <PubSubClient.h>
#include <DHT.h>
#include <EEPROM.h>
const char *ssid = "";
const char *pass = "";
const char *room = "";
const char *update_server = "192.168.15.1";

Keybase proof

I hereby claim:

  • I am teemow on github.
  • I am teemow (https://keybase.io/teemow) on keybase.
  • I have a public key whose fingerprint is 43F3 8C03 302C CD02 D29E C068 C8A8 E3F2 3BAB 4599

To claim this, I am signing this object:

ambassador.service

[Service]
Type=notify
ExecStart=/bin/bash /home/core/ambassador.sh %n registry 5000
ExecStop=/usr/bin/docker stop %n
ExecStopPost=/usr/bin/docker rm %n
NotifyAccess=all

[Unit]
lxc.utsname=my-container
lxc.autodev=1
lxc.tty=1
lxc.pts=1024
lxc.rootfs=/home/teemow/.lxc/my-container/rootfs
lxc.mount=/home/teemow/.lxc/my-container/fstab
lxc.cap.drop=mknod sys_module mac_admin mac_override
lxc.kmsg=0
lxc.stopsignal=SIGRTMIN+4
#networking
#!/bin/sh
ns=my-namespace
in_ns="ip netns exec $ns"
# set up namespace
ip netns add $ns
$in_ns ip link set dev lo up
# add veth interfaces and move one to the namespace
@teemow
teemow / maps.html
Created August 21, 2012 10:29
Google Maps Fusion Tables
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no">
<meta charset="utf-8">
<style>
html, body, #map_canvas {
margin: 0;
padding: 0;
height: 100%;
}
#!/bin/bash
FOLDER=/home/teemow/Projekte/globalguest/www/trunk/app
LANGUAGES=( deu eng )
# update the template (pot)
cake i18n extract -path $FOLDER -output $FOLDER/locale/
for language in ${LANGUAGES[@]}
do
#!/usr/bin/env node
var argv = require('/usr/local/lib/node_modules/optimist')
.usage('Usage: $0 [env]')
.boolean('f')
.argv
, exec = require('child_process').exec
if (argv._.length > 0) env = argv._.shift()
else env = 'production'