Skip to content

Instantly share code, notes, and snippets.

@Sneagan
Sneagan / airpod_availability.html
Last active January 2, 2017 20:22 — forked from blach/airpod_availability.html
Checks AirPod store availability by using JavaScript to query Apple's servers. Created with Textastic and works great with its built-in web preview. Uses YQL and JSONP to work around JavaScript's same origin policy. Inspired by https://gist.github.com/omarshahine/f8eb4598af4f1767ab1a9f01662e74b1
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0" />
<title>Check AirPod availability in Apple Stores</title>
<style>
body {
font-size: 12px;
@Sneagan
Sneagan / rss-subscribers.sh
Last active September 4, 2016 16:17
Podcast-oriented bash script to parse Apache log for a count of RSS subscribers and podcatchers. Currently supports Instacast, Downcast, Podcasts, and the Instacast and iTunes indexers. Emails returned data and writes it to a CSV log file. Based on @marcoarment's RSS Subscriber bash script.
#!/bin/bash
# --- Required variables ---
RSS_URI="/your/rss/file"
MAIL_TO="your@email.com"
LOG_FILE="/your/log/file"
# Log that subscriber numbers will be written to. You will have to create one.
SUBSCRIBER_LOG="/place/to/log/subs"