Skip to content

Instantly share code, notes, and snippets.

View kurobeats's full-sized avatar
😀
wiew

Anthony Cozamanis kurobeats

😀
wiew
View GitHub Profile
@kurobeats
kurobeats / macOS.xml
Created March 5, 2017 06:00
libvirt OSX
<!--
WARNING: THIS IS AN AUTO-GENERATED FILE. CHANGES TO IT ARE LIKELY TO BE
OVERWRITTEN AND LOST. Changes to this xml configuration should be made using:
virsh edit macOS
or other application using the libvirt API.
-->
<domain type='kvm' xmlns:qemu='http://libvirt.org/schemas/domain/qemu/1.0'>
<name>macOS</name>
<uuid>6e79e797-26e8-4cc2-8a37-53695cc5b3b8</uuid>
@kurobeats
kurobeats / box_getter.sh
Created November 1, 2016 01:10
Vagrant to libvirt image maker
#!/usr/bin/bash
d_util=wget
distro=debian
release=jessie64
version=8.6.1
working_dir="/tmp"
boxid=`< /dev/urandom tr -dc a-z-0-9 | head -c8; echo`
inseckey="https://raw.githubusercontent.com/mitchellh/vagrant/master/keys/vagrant"
@kurobeats
kurobeats / terminal.sh
Created October 17, 2016 21:32
Single instance gnome terminal script
#!/usr/bin/env bash
# You'll want xdotool, but other than that, you would be good to go.
# Just download and set keyboard shortcut
if [ "$(xdotool search --onlyvisible --class gnome-terminal)" == "$(xdotool getwindowfocus)" ]; then
xdotool windowminimize $(xdotool getwindowfocus)
exit
fi
if ps aux | grep "[g]nome-terminal" > /dev/null
@kurobeats
kurobeats / raspberry-pi-vpn-router.md
Created September 24, 2016 07:34 — forked from superjamie/raspberry-pi-vpn-router.md
Raspberry Pi VPN Router

Raspberry Pi VPN Router

This is a quick-and-dirty guide to setting up a Raspberry Pi as a "router on a stick" to PrivateInternetAccess VPN.

Requirements

Install Raspbian Jessie (2016-05-27-raspbian-jessie.img) to your Pi's sdcard.

Use the Raspberry Pi Configuration tool or sudo raspi-config to:

ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789

Keybase proof

I hereby claim:

  • I am kurobeats on github.
  • I am kurobeats (https://keybase.io/kurobeats) on keybase.
  • I have a public key whose fingerprint is 93A4 2700 632A 7245 33A1 295C 27F9 5A25 D4C3 F707

To claim this, I am signing this object:

@kurobeats
kurobeats / screenshot.sh
Created August 16, 2016 04:25
Simple screenshot script
#!/bin/bash
while read url
do
timeout 30 phantomjs --ignore-ssl-errors=true /usr/share/phantomjs/examples/rasterize.js "$url" "`echo $url | cut -d "/" -f3`.png"
done < "$@"
#!/usr/bin/env python2
import posixpath
import argparse
import urllib
import os
from SimpleHTTPServer import SimpleHTTPRequestHandler
from BaseHTTPServer import HTTPServer
#!/bin/bash -
#===============================================================================
# vim: softtabstop=4 shiftwidth=4 expandtab fenc=utf-8 spell spelllang=en cc=81
#===============================================================================
#------------------------------------------------------------------------------
# get-remnux.sh
#
# Install or upgrade the REMnux distro on top of a supported Linux distribution.
# See https://REMnux.org for details about REMnux and the installation process.
@kurobeats
kurobeats / pia_archlinux.sh
Last active July 3, 2018 20:37
pia install script
#! /bin/sh -
#
# Install OpenVPN connections for all available
# regions to NetworkManager
#
# Requirements:
# should be run as root
# python and openvpn (will be installed if not present)
#
# Usage: