Skip to content

Instantly share code, notes, and snippets.

@maxheadroom
maxheadroom / sed remove empty lines
Created August 25, 2011 06:57
remove empty lines from text with sed
sed '/^$/d'
@maxheadroom
maxheadroom / EWNAS Glossar
Created May 24, 2012 05:20
#hartejungs nachlese
POS - http://de.wikipedia.org/wiki/Polytechnische_Oberschule
EOS - http://de.wikipedia.org/wiki/Erweiterte_Oberschule
ESP - http://de.wikipedia.org/wiki/Einf%C3%BChrung_in_die_sozialistische_Produktion
TZ - http://de.wikipedia.org/wiki/Technisches_Zeichnen
PA - http://de.wikipedia.org/wiki/Produktive_Arbeit_(DDR)
et al - http://de.wikipedia.org/wiki/Bildungssystem_in_der_DDR
@maxheadroom
maxheadroom / dir-structure-magento
Created July 3, 2013 12:25
gitignore challenge
downloader/...
app/design/frontend/zibev/*
errors/...
skin/frontend/zibev/*
media/...
readme.txt
.gitignore
@maxheadroom
maxheadroom / mount_sparkle.sh
Created October 27, 2013 13:40
A simple shell script to mount a SparkleShare DiskImage on a Mac and start the SparkleShare application
#!/bin/bash -x
# Precondition:
# SparkleShare folder is located into a Mac Sparse Bundle that
# must be mounted before SparkleShare is started
# the user who runs this script needs to get permissions to
# to delete a directory in /Volumes. Therefore sudo is used
# entry in /etc/sudoers:
# %users ALL=(All) NOPASSWD:/bin/rm -rf /Volumes/Sparkle
@maxheadroom
maxheadroom / sparkleshare.config.xml
Created October 29, 2013 08:45
SparkleShare config file to specify different folder location
<?xml version="1.0" encoding="UTF-8"?>
<sparkleshare>
<user>
<name>Your Name</name>
<email>your.name@example.com</email>
</user>
<!-- tell Sparkle that the root for the folders is somewhere else but your home directory -->
<folders_path>/Volumes/Sparkle</folders_path>
<notifications>True</notifications>
### Keybase proof
I hereby claim:
* I am maxheadroom on github.
* I am maxheadroom (https://keybase.io/maxheadroom) on keybase.
* I have a public key whose fingerprint is C746 F84D E9E0 3926 B88B 2DC6 7F2C E31C D9C2 C107
To claim this, I am signing this object:
@maxheadroom
maxheadroom / JIRA-subtickets
Created July 7, 2014 10:04
JIRA find tickets and all their sub-tickets
You need to have a free plugin installed to enable the sub-ticket filter function: https://marketplace.atlassian.com/plugins/com.onresolve.jira.groovy.groovyrunner
Assuming you have a list of tickets that you want to monitor this JQL will find all the sub-tickets as well:
issueFunction in subtasksOf("key in (PKEY-5747, PKEY-5699, PKEY-5404)") OR key in (PKEY-5747, PKEY-5699, PKEY-5404)
@maxheadroom
maxheadroom / Mosh Shell settings
Created August 23, 2014 08:16
MacOS X Bash shell environment settings to make mosh work
# settings for AWS CLI tools
export LANG=en_US.UTF-8
export LC_ALL=en_US.UTF-8
function _update_ps1() {
export PS1="$(~/powerline-shell.py $? 2> /dev/null)"
}
export PROMPT_COMMAND="_update_ps1; $PROMPT_COMMAND"
@maxheadroom
maxheadroom / maintenance.sh
Last active August 29, 2015 14:06
check for AWS maintenance
#!/bin/bash
#
REGIONS="us-east-1 ap-southeast-2 eu-west-1 ap-southeast-1 us-west-2 us-west-1"
JQ=~/Downloads/jq
OPTS="--profile mspprod"
# check for maintenance in above AWS regions
for region in $REGIONS; do
#check for instance in the regions that need maintenance
echo "==================================================="
@maxheadroom
maxheadroom / cUrl documentation
Last active August 29, 2015 14:11
How to gather network timing data with cUrl
Write the following lines into a text file and save as "ctemplate.txt"
\n
time_namelookup: %{time_namelookup}\n
time_connect: %{time_connect}\n
time_appconnect: %{time_appconnect}\n
time_pretransfer: %{time_pretransfer\}n
time_redirect: %{time_redirect}\n
time_starttransfer: %{time_starttransfer}\n
----------\n