Skip to content

Instantly share code, notes, and snippets.

#!/bin/bash
if [ -z "$*" ]; then
echo "No args";
exit 0;
fi
# variables
LOGFILE=$1
LOGFILE_GZ=$LOGFILE.*
@gue-ni
gue-ni / perfect.css
Created May 25, 2021 09:37
More minimal css
body {
max-width: 650px;
margin: 40px auto;
padding: 0 10px;
font: 18px/1.5 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
color: #444;
}
h1,
h2,
body {
margin: 0;
font-family: Roboto, Arial, sans-serif;
color: #3c4043;
line-height: 1.25rem;
}
code {
font-family: source-code-pro, Menlo, Monaco, Consolas, "Courier New", monospace;
@gue-ni
gue-ni / Makefile
Last active August 17, 2021 08:06
Makefile
# $@ := output
# $< := first dependency
CC = gcc
CFLAGS = -std=c99 -pedantic -Wall -g
PROGS = test_program
all: $(PROGS)
rm -f *.o
#!/bin/bash
# server.sh <freq> <port>
rtl_fm -f ${1}M -M fm -s 170k -A fast -r 32k -l 0 -E deemp | nc -lvp ${2}
#!/bin/bash
# client <ip> <port>
nc $1 $2 | play -r 32k -t raw -e s -b 16 -c 1 -V1 -
@gue-ni
gue-ni / b64.c
Last active April 29, 2021 08:28
/*
@author: Jakob Maier
@brief: simple base64 encoder/decoder
*/
#include <stdio.h>
#include <stdlib.h>
#include <stdint.h>
#include <string.h>
#include <assert.h>
#include <unistd.h>