Skip to content

Instantly share code, notes, and snippets.

View yuvadm's full-sized avatar

Yuval Adam yuvadm

View GitHub Profile
@yuvadm
yuvadm / yaourt_install.sh
Last active October 5, 2015 08:20
Yaourt (AUR helper) Installation
sudo pacman -S --noconfirm base-devel yajl wget
cd /tmp
wget https://aur.archlinux.org/cgit/aur.git/snapshot/package-query.tar.gz
wget https://aur.archlinux.org/cgit/aur.git/snapshot/yaourt.tar.gz
tar zxvf package-query.tar.gz
tar zxvf yaourt.tar.gz
cd package-query
makepkg -i
@yuvadm
yuvadm / ddns
Created January 2, 2015 12:25
zzzz.io OpenWRT DDNS script
config service "myddns"
option enabled "1"
option interface "wan"
option use_syslog "1"
option service_name "zzzz.io"
option domain "example.zzzz.io"
option force_interval "72"
option force_unit "hours"
@yuvadm
yuvadm / embed.c
Created January 11, 2015 09:43
Small C program for liberating TTF fonts, fixes the `embed` flag
/*
* This program is for setting TTF files to Installable Embedding mode.
*
* Note that using this to embed fonts which you are not licensed to embed
* does not make it legal.
*
* This code was written by Tom Murphy 7, and is public domain. Use at your
* own risk...
*/
@yuvadm
yuvadm / install.sh
Created September 19, 2015 13:25
Arch Linux installation on Asus F201E
# Arch Linux installation procedure on an Asus F201E
# UEFI boot + SSD + LVM + LUKS + TRIM + discards
# Randomize (or zero) drive contents
dd if=/dev/urandom of=/dev/sda
# Create GPT and partitions
# Use gdisk to ensure proper partition alignment
gdisk /dev/sda
# 400MB boot partition on /dev/sda1 type ef00
@yuvadm
yuvadm / 32c3
Created December 26, 2015 18:31
Netctl config for 32c3
Description='32C3 secure WPA2 802.1X config'
Interface=wls1
Connection=wireless
Security=wpa-configsection
IP=dhcp
ESSID=32C3
WPAConfigSection=(
'ssid="32C3"'
'proto=RSN WPA'
'key_mgmt=WPA-EAP'
@yuvadm
yuvadm / unsign.py
Created January 13, 2016 10:46
Unwrap gov.il signed documents
from base64 import b64decode
from os import listdir
from sys import argv
from xml.dom.minidom import parse
def unsign(filenames):
for f in filenames:
try:
dom = parse(f)
except IOError:
@yuvadm
yuvadm / ffmpeg-over-ssh.sh
Created February 7, 2016 23:10
Media stream pipe ffmpeg over SSH
ssh [email protected] "ffmpeg -i $URL -c copy -f nut pipe:1" | ffplay -i pipe:0
{
"pitch": 0,
"sprite": "mapbox://sprites/mushon/cijzh8i5u0101bmkvm2sxj5l0",
"draft": false,
"owner": "mushon",
"name": "Daat Hamakom Default",
"glyphs": "mapbox://fonts/mushon/{fontstack}/{range}.pbf",
"center": [
13.2797674709783,
38.21471825979131
{
"id": "cijzh8i5u0101bmkvm2sxj5l0",
"center": [
13.2797674709783,
38.21471825979131
],
"metadata": {
"mapbox:groups": {
"1452119469254.1111": {
"name": "default",
{
"name": "Daat Hamakom Default",
"sources": {
"mapbox://mushon.277625nf": {
"url": "mapbox://mushon.277625nf",
"type": "vector"
},
"mapbox://mapbox.mapbox-streets-v7": {
"url": "mapbox://mapbox.mapbox-streets-v7",
"type": "vector"