Skip to content

Instantly share code, notes, and snippets.

View gvoysey's full-sized avatar
🌯

Graham Voysey gvoysey

🌯
View GitHub Profile
@gvoysey
gvoysey / FakeNameGenerator.cs
Created August 31, 2015 15:19
A generator for fake names
public class FakeNameGenerator
{
private static readonly Random Random = new Random();
private static readonly List<string> _vowels = new List<string> {"a", "e", "i", "o", "u"};
private static readonly List<string> _consonants = new List<string>
{
"b", "c", "d", "f", "g", "h", "j", "k", "l", "m", "n", "p", "q",
"r", "s", "t", "v", "w", "x", "y", "z"
@gvoysey
gvoysey / SMS-IP
Last active July 28, 2016 18:23
Texts you your IP address (useful for headless linux boxes, raspberry pis, etc)
#!/bin/bash
myIP=$(ip addr | grep 'state UP' -A2 | tail -n1 | awk '{print $2}' | cut -f1 -d'/')
commandString="curl http://textbelt.com/text -d number=1111111111 -d \"message=$myIP\""
$(eval $commandString)
#call this script from /etc/rc.local with (eval "/path/to/thisscript"); get a text every time your machine reboots with the new IP.