This gist shows how to create a GIF screencast using only free OS X tools: QuickTime, ffmpeg, and gifsicle.
To capture the video (filesize: 19MB), using the free "QuickTime Player" application:
CURL | |
curl -o /dev/null -w "Connection Time: %{time_connect} TTFB: %{time_starttransfer} Total Time: %{time_total} \n" https://example.com/ | |
Documentation & formatting variables: | |
https://curl.haxx.se/docs/manpage.html#-w | |
Apache Bench | |
ab -n 1000 -c 100 https://example.com/ |
Recommended Repos | |
https://wiki.centos.org/AdditionalResources/Repositories | |
PHP | |
https://ius.io/ | |
OSX DiskUtility Format | |
sudo diskutil eraseDisk FAT32 NAME MBRFormat /dev/disk1 | |
Copy Image | |
sudo dd bs=1m if=/path/to/raspbian.img of=/dev/disk1 | |
Setup | |
https://www.losant.com/blog/getting-started-with-the-raspberry-pi-zero-w-without-a-monitor | |
PiZero W does not support 5GHz WiFi |
<?php | |
/** | |
* Reference: https://websmartdesign.nz/searching-structured-post-data-with-wordpress/ | |
*/ | |
// Join wp_postmeta | |
add_filter('posts_join', function($join) { | |
global $wpdb; | |
$join .= "LEFT JOIN {$wpdb->postmeta} ON ({$wpdb->posts}.ID = {$wpdb->postmeta}.post_id) "; |
#!/bin/bash | |
run() | |
{ | |
/usr/share/elasticsearch/bin/elasticsearch-plugin $1 | |
} | |
init() | |
{ | |
# Get installed plugins |
<?php | |
/** | |
* Force Login | |
*/ | |
function force_login() { | |
if (!is_user_logged_in()) { | |
$url = home_url($_SERVER['REQUEST_URI']); | |
$whitelist = []; |
# Aliases | |
alias c="clear" | |
alias ll="ls -lah" | |
alias lz="ls -laZ" # include (selinux) security context in listing | |
alias cl="c && ll" | |
alias ..="cd .." | |
# Empty contents of files | |
empty() { | |
for arg in "$@" |
/** | |
* @see http://mashe.hawksey.info/2014/07/google-sheets-as-a-database-insert-with-apps-script-using-postget-methods-with-ajax-example/ | |
* @see https://gist.github.com/willpatera/ee41ae374d3c9839c2d6 | |
*/ | |
// Sheet name | |
const SHEET_NAME = "Submissions"; | |
// Property service | |
const ScriptProps = PropertiesService.getScriptProperties(); |
<?php | |
/* | |
Plugin Name: GraphQL Meta Queries | |
Plugin URI: https://loganstellway.com | |
Description: Extends WPGraphQL to allow meta queries on post connections | |
Version: 0.0.1 | |
Author: Logan Stellway | |
Author URI: https://loganstellway.com | |
*/ |