I hereby claim:
- I am forsgren on github.
- I am forsgren (https://keybase.io/forsgren) on keybase.
- I have a public key whose fingerprint is DCEF ADC2 8558 3417 3AAF A446 1B07 913F 6353 392F
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
function reloadThisPagePlz() { | |
var reload_variants=["location=location","location=location.href","location=window.location","location=self.location","location=window.location.href","location=self.location.href","location=location['href']","location=window['location']","location=window['location'].href","location=window['location']['href']","location=window.location['href']","location=self['location']","location=self['location'].href","location=self['location']['href']","location=self.location['href']","location.assign(location)","location.replace(location)","window.location.assign(location)","window.location.replace(location)","self.location.assign(location)","self.location.replace(location)","location['assign'](location)","location['replace'](location)","window.location['assign'](location)","window.location['replace'](location)","window['location'].assign(location)","window['location'].replace(location)","window['location']['assign'](location)","window['location']['replace'](location)","self.location['assi |
##Date and Time
=TIMEVALUE(SUBSTITUTE("{{OccurredAt}}"," at ", " ")) + DATEVALUE(SUBSTITUTE("{{OccurredAt}}"," at ", " "))
##Date
=DATEVALUE(SUBSTITUTE("{{OccurredAt}}"," at ", " "))
##Time
/* | |
Copy this into the console of any web page that is interactive and doesn't | |
do hard reloads. You will hear your DOM changes as different pitches of | |
audio. | |
I have found this interesting for debugging, but also fun to hear web pages | |
render like UIs do in movies. | |
*/ | |
const audioCtx = new (window.AudioContext || window.webkitAudioContext)() |
# based on http://www.commandlinefu.com/commands/view/2916/backup-all-mysql-databases-to-individual-files | |
# but modified for the MAMP path and to include default root/root as username and password | |
for I in $(/Applications/MAMP/Library/bin/mysql -u root -proot -e 'show databases' -s --skip-column-names); do /Applications/MAMP/Library/bin/mysqldump -u root -proot $I | gzip > "$I.sql.gz"; done |
mysql -u root -p < /path/to/sql/frile/multiDB.sql |
#!/usr/bin/env php | |
<?php | |
/** | |
* PHP script to replace site url in Wordpress database dump, even with WPML | |
* @link https://gist.github.com/lavoiesl/2227920 | |
*/ | |
if (!empty($argv[1]) && $argv[1] == 'update') { | |
$file = file_get_contents('https://gist.github.com/lavoiesl/2227920/raw/wordpress-change-url.php'); | |
if ($file === false) { |
defaults write com.apple.dock size-immutable -bool true; killall Dock |
#!/usr/bin/env zsh | |
sleep 10 &! | |
pid=$! # Process Id of the previous running command | |
spin='⠋⠙⠚⠞⠖⠦⠴⠲⠳⠓' | |
i=0 | |
while kill -0 $pid 2>/dev/null; do | |
i=$(((i + 1) % 10)) | |
printf "$fg[magenta]\r${spin:$i:1}" |
Unless otherwise noted (either in this file or in a file's copyright section) the contents of this gist are Copyright ©️2020 by Christopher Allen, and are shared under spdx:Creative Commons Attribution Share Alike 4.0 International (CC-BY-SA-4.) open-source license.
If you more tips and advice like these, you can become a monthly patron on my GitHub Sponsor Page for as little as $5 a month; and your contributions will be multipled, as GitHub is matching the first $5,000! This gist is all about Homebrew, so if you like it you can support it by donating to them or becoming one of their Github Sponsors.