This file contains 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
#!/usr/bin/env bash | |
set -e | |
# Compare images between two Grid environments | |
# Assumes: | |
# - grid-cli installed `brew install guardian/devtools/grid-cli` | |
# - `test` and `prod` profiles configured `grid configuration:add` | |
# How it works: | |
# - Download image from PROD |
This file contains 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
<!DOCTYPE html> | |
<html> | |
<head></head> | |
<body> | |
<button type="button" onclick="window.parent.postMessage({name: 'foo'}, '*');"> | |
Press Me | |
</button> | |
</body> | |
</html> |
This file contains 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 | |
curl --write-out %{time_total}\\n --output /dev/null --silent $1 |
This file contains 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
if (! Boolean(document.querySelector('.yt-uix-subscription-button').getAttribute('data-is-subscribed'))) { | |
document.querySelector('.comment-section-renderer-items').style.display = 'none' | |
} |
This file contains 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
# Get YouTube ChannelId (from a Video page) | |
var channelId = $('meta[itemprop=channelId]').content; |
This file contains 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 | |
: ' | |
Toggle the power of Lifx bulbs. | |
Save to a directory on your PATH for simplicity - remember to give it execute permissions! | |
Requires a Lifx token (https://community.lifx.com/t/creating-a-lifx-http-api-token/25) to be stored in $HOME/.config/lifx/token | |
' | |
TOKEN=`cat $HOME/.config/lifx/token` |
This file contains 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 | |
if [ $# -ne 1 ] | |
then | |
echo "usage: exifcats.sh <FILE>" | |
echo | |
echo "Displays the IPTC category information for an image." | |
echo | |
exit 1 | |
fi |
This file contains 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
/** | |
* ABOUT | |
* Google Apps Script to post a message to Slack when someone responds to a Google Form. | |
* | |
* Uses Slack incoming webhooks - https://api.slack.com/incoming-webhooks | |
* and FormsResponse - https://developers.google.com/apps-script/reference/forms/form-response | |
* | |
* | |
* AUTHOR | |
* Akash A <github.com/akash1810> |
This file contains 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/sh | |
aws ec2 describe-instances --filters "Name=private-ip-address,Values=$1" | jq -c '.Reservations[0].Instances[].PublicDnsName' |
This file contains 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/sh | |
compass-rvm-init () { | |
rvm --ruby-version use 2.1.1@$1 --create | |
bundle init | |
echo "gem 'compass'" | tee -a Gemfile | |
bundle update | |
} | |
alias compass-rvm-init=compass-rvm-init |