Skip to content

Instantly share code, notes, and snippets.

View aqualad's full-sized avatar

Bryan Dodd aqualad

  • OnShift
  • Cleveland, OH
View GitHub Profile
@aqualad
aqualad / BlockPS4Updates
Created May 20, 2021 19:08
pi hole adlist to block ps4 updates
# Exploited PS4 Blocklist (https://gbatemp.net/threads/aio-ps4-exploit-guide.497858/)
#[community.playstation.net]
asm.np.community.playstation.net
ps4.updptl.np.community.playstation.net
ps4.updptl.sp-int.community.playstation.net
ps4updptl.eu.np.community.playstation.net
ps4updptl.jp.np.community.playstation.net
ps4updptl.jp.sp-int.community.playstation.net
ps4updptl.uk.np.community.playstation.net
@aqualad
aqualad / sqlalchemy_debugger.py
Created April 16, 2019 13:07 — forked from nZac/sqlalchemy_debugger.py
SQLAlchemy query to compiled SQL string
try:
import sqlparse.format as sqlformat
except ImportError:
def sqlformat(query, **kwargs):
"""Monkey patch sqlparse.format if package not installed"""
return query
def debug_query(query, engine):
"""Return a parametrized and formated sql query for debugging

Keybase proof

I hereby claim:

  • I am aqualad on github.
  • I am aqualad (https://keybase.io/aqualad) on keybase.
  • I have a public key ASCCIkNZTWVOVVIXNao99vyMuhT8eFzvcf0WQziuX-Xc7go

To claim this, I am signing this object:

@aqualad
aqualad / Fix babel-eslint crashes.md
Last active March 31, 2017 17:04
Fix for eslint crashing in Sublime when missing babel-eslint
  1. In the application toolbar
    Select Sublime Text > 
        Preferences > 
            Package Settings > 
                Either Babel or ESLint > 
                    Settings Default
    
  2. Find the setting for the node_modules install path in OS X
  • currently located at /usr/local/lib/node_modules
@aqualad
aqualad / qa2.yml
Last active January 4, 2017 14:26 — forked from abilancini/qa2.yml
teams:
- name: Purple
description: nothing compares 2 U
- name: Green
description: blah blah blah
- name: Magenta
- name: Olive
employees:
-
@aqualad
aqualad / generate_uuids.py
Created October 5, 2016 01:39
Generate multiple UUIDs
from uuid import uuid4()
newline_in = 4 # newline after x rows
number_of_uuids = 4 * 16 # how many uuids to generate
for i in range(0, number_of_uuids):
if i and i % newline_in == 0:
print(" ")
uuid4()
@aqualad
aqualad / ES6-Map-Reduce.js
Created September 28, 2016 21:55
javascript Map and Reduce examples
let selector,
$elements,
testsPassed,
totalTestsPassed;
// Select the 7th <td> from every <tr>, excluding the first <tr>
selector = '#testresult tr:not(:first-child) td:nth-child(7)';
// Get array of selected elements
$elements = $$
@aqualad
aqualad / tmux-cheatsheet.markdown
Created August 15, 2016 22:55 — forked from MohamedAlaa/tmux-cheatsheet.markdown
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
@aqualad
aqualad / ES6-Debounce-Test.js
Created August 8, 2016 02:18
Testing ES6 fat arrow and lodash debounce together
function foo(s) { console.log(s); };
let d = _.debounce((s) => foo(s), 500);
$newEl = document.createElement('button');
$newEl.onclick = d;
$target = document.body;
$target.insertBefore($newEl, $target.childNodes[0]);