Skip to content

Instantly share code, notes, and snippets.

@scumola
scumola / dots.py
Created April 10, 2026 18:35
Dots and lines in SVG format
import drawsvg as draw
import math
import random
spacing = 7
stroke = 0.5
rows, cols = (200, 200)
arr = [[0]*(cols*2)]*(rows*2)
d = draw.Drawing(450, 450, origin='center')
@scumola
scumola / pads.py
Created March 23, 2026 23:16
circles and lines in a grid (SVG)
#!/usr/bin/env python3
import drawsvg as draw
import math
import random
spacing = 12
stroke = 0.5
d = draw.Drawing(450, 450, origin='center')
for x in (range(-200, 200, spacing+1)):
for y in (range(-200, 200, spacing+1)):
size = random.randint(1,spacing)
@scumola
scumola / src-domains.uniq.by-freq.txt
Last active January 15, 2020 17:08
url shorteners/redicters found in the 2019 2% twitter stream (domains that had urls tweeted which responded with a 301 or 302 redirect)
119154 bit.ly
29522 t.co
6175 dlvr.it
3466 dingtone.me
2789 youtu.be
2701 ow.ly
1809 talkyou.me
1622 twitch.tv
1616 tylt.it
1533 whounfollowedme.org

Keybase proof

I hereby claim:

  • I am scumola on github.
  • I am stevewebb (https://keybase.io/stevewebb) on keybase.
  • I have a public key whose fingerprint is 7B25 218D 3793 8D15 66FD B536 EB84 F4ED 77EB C9DD

To claim this, I am signing this object:

#!/usr/bin/python
from bs4 import BeautifulSoup as BS
import requests
import re
import time
import sys
import gspread
from oauth2client.service_account import ServiceAccountCredentials
scope = "https://spreadsheets.google.com/feeds"
$ node index.js kat.torrent ~/Downloads/ 8080
/Users/stevenwebb/Downloads/torrent-peek/index.js:58
ffi.Callback('void', ['pointer', 'string', 'string'], (alert, msg, type) => {
^
SyntaxError: Unexpected token >
at Module._compile (module.js:439:25)
at Object.Module._extensions..js (module.js:474:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
@scumola
scumola / pet-snippet.toml
Last active April 5, 2017 22:56
description
[[snippets]]
description = "Get my public IP"
command = "curl ifconfig.co"
output = ""
[[snippets]]
description = "Check SSL start and end dates"
command = "echo | openssl s_client -connect badcheese.com:443 2>/dev/null | openssl x509 -dates -noout"
output = ""
@scumola
scumola / eb-csshx.bash
Last active July 22, 2016 20:22
csshx-beanstalk.bash
#!/bin/bash
if [ "$#" -ne 1 ];
then echo "USAGE: $0 <EB Environment Name>"
exit
fi
rm /tmp/csshx-hosts.txt &> /dev/null
for id in `/usr/local/bin/aws elasticbeanstalk describe-environment-resources --output text --environment-name $1 | grep INSTANCES | awk '{print $2}'` ;
do
ids+=$(echo $id|tr '\n' ' ')
done
@scumola
scumola / gist:bfd9775c246f71ca93deb363292aa9bb
Created July 15, 2016 17:26
radish.calls fluentd payload example (sanitized)
{
"request_params" : {
"uuid" : "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
"controller" : "api/v20/egi",
"maxcount" : 10000,
"nkey" : "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
"fields" : "start_date_time,end_date_time,name,description,episode_description,episode_title,theme,channel_hd_fl,is_new,service_id,network_affiliate_name,images.poster_url,images.program_logo_url,upid,original_air_date,service_unique_id,run_time,egid_for_sge,tms_id,tv_rating,mpaa_rating,channel_information.is_hd,channel_information.callsign,channel_information.channel_image,channel_information.channel,sport_team_home_id,sport_team_away_id,images.home_team_image_url,images.away_team_image_url,kind,slug",
"unlocked_user_networks" : [
1,
2,
<?xml version="1.0" encoding="UTF-8"?>
<!--
HERITRIX 3 CRAWL JOB CONFIGURATION FILE
This is a relatively minimal configuration suitable for many crawls.
Commented-out beans and properties are provided as an example; values
shown in comments reflect the actual defaults which are in effect
if not otherwise specified specification. (To change from the default
behavior, uncomment AND alter the shown values.)