Skip to content

Instantly share code, notes, and snippets.

View srspnda's full-sized avatar

Justin Poole srspnda

View GitHub Profile
@tobert
tobert / gist:721a65762337ba504291
Created January 21, 2015 21:09
Two Necessary Kernel Tweaks for Linux Systems / Shaun Thomas / pgsql-performance@
Credit: Shaun Thomas
via: http://www.postgresql.org/message-id/50E4AAB1.9040902@optionshouse.com
Two Necessary Kernel Tweaks for Linux Systems
From: Shaun Thomas <sthomas(at)optionshouse(dot)com>
To: "pgsql-performance(at)postgresql(dot)org" <pgsql-performance(at)postgresql(dot)org>
Subject: Two Necessary Kernel Tweaks for Linux Systems
Date: 2013-01-02 21:46:25
Message-ID: 50E4AAB1.9040902@optionshouse.com (view raw or flat)
@zxjinn
zxjinn / DirectoryUnzip.sh
Created January 18, 2013 06:09
Finds all zip files in the current directory, and its sub-directories, then unzips them into folders in the current directory that are named the same as the zip files and sub-directory names. For example: ./subdir/file.zip -> ./subdir_file/extractedfile. Tested on Ubuntu 12.04 with Unzip 6.00.
#!/bin/bash
# Extracts all zipfiles in subdirectories to current directory.
for source in $(find . -name "*.zip")
do
unzip -tq $source
retval=$?
if [ $retval -eq 0 ]
then