Skip to content

Instantly share code, notes, and snippets.

View rey's full-sized avatar
🌴
On vacation

Rey Dhuny rey

🌴
On vacation
View GitHub Profile
@Sonictherocketman
Sonictherocketman / pinboard-weekly-newsletter.sh
Created April 3, 2021 20:28
A personalized weekly Pinboard-based newsletter of pages you said you wanted to read.
set -e;
# Creates a simple email message containing links from your recent Pinboard
# bookmarks that are marked as "to read".
echo "[$(date)] Beginning pinboard weekly summary...";
CREDS="user:token"
TO="$(date -u +'%Y-%m-%dT%H:%M:%SZ')"
@tomhicks
tomhicks / plink-plonk.js
Last active March 18, 2024 02:23
Listen to your web pages
#!/bin/bash
#
# A script that takes a Twitter data archive, which is produced as a
# set of JavaScript files (different from the regular archive, which
# is CSV and HTML), and converts the `tweet.js` file, which contains
# all of the tweets, into tractable JSON, one tweet per line. It then
# inserts /that/ into a SQLite3 database, and extracts a simple
# relational table of tweets from the JSON. Finally, it runs datasette
# on the resulting database to allow you to explore.
@dfletcher
dfletcher / tsws
Last active July 21, 2018 12:47
Totally simple web server using Bash and netcat (nc)
Moved to a proprer repositoy, TSWS is a real boy now!
https://github.com/dfletcher/tsws
PRs welcomed.
@jamescmartinez
jamescmartinez / slack_delete.rb
Last active January 4, 2021 21:28
This Ruby script will bulk remove all Slack files older than 30 days. Just add your API token from https://api.slack.com/web#authentication into the token quotes at the top of the file.
require 'net/http'
require 'json'
require 'uri'
@token = ''
def list_files
ts_to = (Time.now - 30 * 24 * 60 * 60).to_i # 30 days ago
params = {
token: @token,
@jayliu50
jayliu50 / slackDownloadThenDelete.py
Last active January 27, 2016 23:23
Download then delete files older than 14 days from Slack
import sys
import requests
import json
import calendar
from datetime import datetime, timedelta
# This script will download, then delete the non-external files older than 14 days.
_token = "" # administrator token, from https://api.slack.com/web
_project = "" # project name, from http://[project].slack.com
@adelevie
adelevie / .travis.yml
Created April 9, 2015 18:15
Automated accessibility testing using Travis-CI and pa11y
before_script:
- npm install -g http-server
- npm install -g pa11y
- npm install -g pa11y-reporter-ci
script:
- nohup http-server -p 8080 >/dev/null 2>&1 &
- pa11y localhost:8080/index.html -r ci -s WCAG2AAA
INITIALISATION
==============
load wp-config.php
set up default constants
load wp-content/advanced-cache.php if it exists
load wp-content/db.php if it exists
connect to mysql, select db
load object cache (object-cache.php if it exists, or wp-include/cache.php if not)
load wp-content/sunrise.php if it exists (multisite only)

Font Face

A mixin for writing @font-face rules in SASS.

Usage

Create a font face rule. Embedded OpenType, WOFF2, WOFF, TrueType, and SVG files are automatically sourced.

@include font-face(Samplino, fonts/Samplino);
#!/bin/bash
#
# _ _ __
# __ _ __ _ _ __| |__ (_)/ _|_ _
# / _` |/ _` | '__| '_ \| | |_| | | |
#| (_| | (_| | | | |_) | | _| |_| |
# \__, |\__,_|_| |_.__/|_|_| \__, |
# |___/ |___/
#
#