- Dancing in the Dark / All My Friends
- BBC highlights
- Foo Fighters cancelled due to Dave Grohl’s broken leg
- The Libertines (BBC highlights) moved forward
- Without this, might have missed Hot Chip
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Checks a server certificate chain for old USERTrust intermediate cert, | |
# which will expire in May 2020. | |
# | |
# Possible output: | |
# | |
# • Error (e.g. cannot connect to host) | |
# • Not a Sectigo/Comodo chain (cannot find one of the CAs) | |
# • New USERTrust root cert found (valid, but superfluous) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
github=$(curl -s https://api.github.com/meta | jq -r '.web | .[]' | sed 's~/32~~' | sort) | |
ufw=$(ufw status | grep '# GitHub' | awk '{print $1}' | sort) | |
comm -13 <(echo "$ufw") <(echo "$github") | while read addition; do | |
echo "Adding $addition" | |
ufw allow out to $addition port 22 comment GitHub | |
done |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$base = 'https://www.change.org/api-proxy/-/comments'; | |
$options = ['commentable_type' => 'Event', 'commentable_id' => 15409786, 'role' => 'comment']; | |
$complete = false; | |
// API blocks PHP user-agent | |
$context = stream_context_create(['http' => ['header' => "User-Agent: parser/1.0.0\r\n"]]); | |
$fh = fopen('comments.csv', 'w'); | |
set_time_limit(0); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
fail() { | |
[ $raw -eq 1 ] && out=Fail || out=$1 | |
echo -n -e "\e[91m$out\e[39m " | |
} | |
pass() { | |
[ $raw -eq 1 ] && out=Pass || out=$1 | |
echo -n -e "\e[32m$out\e[39m " |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
HOSTNAME=your.dns.here | |
UFW=/usr/sbin/ufw | |
if [[ $EUID -ne 0 ]]; then | |
echo "This script must be run as root" | |
exit 1 | |
fi | |
new_ip=$(dig +short $HOSTNAME) |
- Baader–Meinhof phenomenon: tendency to notice something more often after becoming aware of it
- Cobra effect: an incentive to fix a problem makes it worse
- Dunning–Kruger effect: illusion of cognitive superiority
- Leidenfrost effect: droplets of water float on hot surface
- Mandela effect: false memories shared by multiple people
These snippets are to highlight a minor display discrepancy between desktop and mobile link unfurling in Slack.
The article:published_time
OpenGraph tag can have an optional time component. When unfurling links, desktop always treats the tag as a date, and mobile always treats it as a datetime, regardless of the content of the tag.
The content can essily be passed into Slack using raw.githack.com:
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
function msisdn() { | |
sed 's/^0/44/' <<< "$1" | |
} | |
API=https://rest.nexmo.com/sms/json | |
KEY= # Nexmo API key | |
SECRET= # Nexmo API secret | |
DEFAULT= # Default SMS sender |