Skip to content

Instantly share code, notes, and snippets.

@karschsp
karschsp / gist:1defbb85e5154325799b9182ff350bb7
Created December 13, 2017 17:11
instapaper text bookmarklet
javascript: function iptxt() {
var d = document;
try {
if (!d.body) throw (0);
window.location = 'http://www.instapaper.com/text?u=' + encodeURIComponent(d.location.href);
} catch (e) {
alert('Please wait until the page has loaded.');
}
}
iptxt();
Black vs Blue
## The Jones'
Every so often, my wife will complain about how so-and-so has a bigger basement than ours or such-and-such just bought a new car or whatever. I have to remind her that it's all perception. The reality is that they share the same reality that we do. Mortgage payments, late bills, screaming kids, medical issues, etc.
*Perception/Reality*
## Anti- and social
Verifying that +stevekarsch is my blockchain ID. https://onename.com/stevekarsch
@karschsp
karschsp / my.cnf
Created October 5, 2015 15:46
my.cnf
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
user=mysql
# Disabling symbolic-links is recommended to prevent assorted security risks
symbolic-links=0
max_allowed_packet=128M
max_connections=15
query_cache_size=16M
join_buffer_size=1M
@karschsp
karschsp / gist:84bd1b7e019515acf27a
Created September 10, 2015 01:39
css play button
.channel__image:hover:before, .bxslider li a:hover:before {
content: " ";
border-radius: 50%;
width: 50px;
height: 50px;
margin-left: -25px;
margin-top: -25px;
color: #000000;
text-align: center;
position: absolute;
@karschsp
karschsp / 0_reuse_code.js
Last active August 29, 2015 14:26
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@karschsp
karschsp / gist:6f3dff95934b8cabb3c5
Created July 2, 2015 12:32
Monitor progress while importing MySQL DB
pv <mysql-dump-file>.sql | mysql -u root <dbname>
@karschsp
karschsp / gist:89e84bc5c7c891cd17c3
Last active August 29, 2015 14:24
First commands to run after installing D7
drush dis -y overlay shortcut rdf toolbar dashboard comment && drush en -y views views_ui pathauto imagemagick admin_menu admin_menu_toolbar bootstrap jquery_update admin_devel devel date date_api date_tools diff search_krumo features strongarm media
@karschsp
karschsp / fixperms.sh
Created February 22, 2015 03:02
fix perms
#! /bin/bash
#
# From anywhere within a Drupal site,
# this will set the correct permissions
# to keep Drupal happy.
#
CURRENT_USER=`who am i | awk '{print $1}'`
USER=${1:-$CURRENT_USER}
dir=`drush status --fields=root |cut -f2 -d: |sed s/\ //g`
@karschsp
karschsp / gist:502d255ace8797f02bfa
Created December 1, 2014 14:15
Set up a blank BuyVM web server
apt-get update
apt-get install nano
mkdir .ssh
cd .ssh
nano authorized_keys
apt-get install apache2
apt-get install dialog
apt-get install mariadb-server mariadb-client
apt-get install php5 php5-mysql libapache2-mod-php5
cd /var/www