I hereby claim:
- I am joshbetz on github.
- I am jshbz (https://keybase.io/jshbz) on keybase.
- I have a public key ASAFzmaBfBKpti-EyZzScwo_nT3wNtqU0nIIP7SBmqaBMAo
To claim this, I am signing this object:
#!/bin/bash | |
trap stop SIGINT SIGHUP | |
usage() { | |
track=`basename $0` | |
echo "usage: $track <time> <name> [--quiet]" | |
} | |
# Validate usage |
" relative line numbers | |
set relativenumber | |
autocmd InsertEnter * :set number | |
autocmd InsertLeave * :set relativenumber |
" make < > shifts keep selection | |
vnoremap < <gv | |
vnoremap > >gv |
<?php | |
/** | |
* Plugin Name: Photon Lossy Compression | |
* Plugin URI: https://josh.blog/2015/01/lossy-compression-with-photon | |
* Description: Lossy compression of images using the Jetpack Photon CDN. | |
* Version: 1.0.0 | |
* Author: Josh Betz | |
* Author URI: https://josh.blog | |
* License: GPL-2.0+ | |
* License URI: http://www.gnu.org/licenses/gpl-2.0.txt |
<?php | |
// https://wordpress.org/plugins/wp-user-activity/ | |
/** | |
* Don't allow users to delete or edit their activity. | |
* | |
* If the site has been hacked, make it hard for attackers | |
* to cover their steps. | |
*/ |
#!/bin/bash | |
client_id=$1 | |
client_secret=$2 | |
redirect_uri=$3 | |
if [[ -z $client_id || -z $client_secret || -z $redirect_uri ]]; then | |
echo "Usage: $0 <client_id> <client_secret> <redirect_uri>" | |
exit 1 | |
fi |
I hereby claim:
To claim this, I am signing this object:
#!/usr/bin/env node | |
/** | |
* External dependencies | |
*/ | |
const cluster = require( 'cluster' ); | |
const CPUs = require( 'os' ).cpus().length; | |
// Process config | |
const PROC_TITLE = 'node-server'; |
struct Webview: UIViewControllerRepresentable { | |
let url: URL | |
func makeUIViewController(context: Context) -> WebviewController { | |
let webviewController = WebviewController() | |
let request = URLRequest(url: self.url, cachePolicy: .returnCacheDataElseLoad) | |
webviewController.webview.load(request) | |
return webviewController |
import SwiftUI | |
import WebKit | |
struct ContentView: View { | |
var body: some View { | |
Webview(url: URL(string: "https://google.com")!) | |
} | |
} | |
struct Webview: UIViewRepresentable { |