Skip to content

Instantly share code, notes, and snippets.

@Two9A
Two9A / vertstitch.sh
Created May 12, 2018
Vertical stitch: Take a set of (in this case 598) frames from a phone scroll recording, and rebuild the original list being scrolled
View vertstitch.sh
#!/bin/bash
BLOBH=256
BLOBX=0
BLOBY=0
convert az0001.jpg final.png
BLOBW=$(identify -format "%w" final.png)
FULLWIDTH=$(identify -format "%w" final.png)
for filenum in {1..597}; do
@Two9A
Two9A / user.css
Last active Apr 29, 2016
User CSS on top of /r/SpaceX's style (FIrefox/Stylish)
View user.css
@-moz-document regexp("https?:\\/\\/(?!.*i\\.).*\\.reddit\\.com.*") {
body.res-r-spacex { top: 110px; background: none !important; }
body.res-r-spacex #header { top: -110px; height: 110px; }
body.res-r-spacex #header #sr-header-area { background: hsl(0, 0%, 20%); }
body.res-r-spacex #header #header-bottom-left { height: 90px; }
body.res-r-spacex #header #header-bottom-right { background: hsl(0, 0%, 20%); top: 0; }
body.res-r-spacex #header #header-bottom-right::before { border-top-color: hsl(0, 0%, 20%); }
body.res-r-spacex #header #header-img-a { height: 90px; background-size: 130px 90px; background-position: 10px -5px; }
body.res-r-spacex #header div#header-bottom-left .redditname a { background-size: 210px 90px; height: 90px; }
body.res-r-spacex #header div#header-bottom-left ul.tabmenu { height: 90px; }
@Two9A
Two9A / robin-filter.js
Last active Apr 3, 2016
Robin filter and vote clock
View robin-filter.js
// ==UserScript==
// @name Robin Autovoter
// @namespace http://jerl.im
// @version 1.9
// @description Autovotes via text on /r/robin
// @author /u/keythkatz
// @match https://www.reddit.com/robin*
// @grant none
// ==/UserScript==
/* jshint -W097 */
@Two9A
Two9A / 20151222-#spacex.log
Last active Dec 22, 2015
#spacex log, Orbcomm-2 launch/landing
View 20151222-#spacex.log
0106:<@B787_300> WE ARE LIVE
0106:< bigboateng> where do we see T- count
0106:< michaeltherobot> it's on!
0106:< SpaceX_guest|47418> IVE
0106:< Raptor42> Stream live
0106:<+theholyduck> yaysk
0106:< Qqqwxs> Totally the music is great
0106:< SpaceX_guest|47418> LIVE
0106:< Bernardo> oooooohohoohohohoohohh
0106:< arth> hahaha
@Two9A
Two9A / boot.asm
Created Oct 31, 2015
ph34rOS! I never got very far with this...
View boot.asm
;--------------------------------------------------------------------------
; ph34rOS - Testing boot sector version 0.0.1h
; Changes from 0.0.1g - Removed Alias descriptor (No use for it)
; - Moved Stage2 load point to 7E00
; - Assuming 386+ (It's a reasonable assumption)
; - Optimised debugging messages (I was bored)
; - Removed GetKey (No need, no need at all)
; - Moved procs into main code (no CALLs!)
;--------------------------------------------------------------------------
View damn-irc.php
<?php
require_once 'html5/html5.inc.php';
class dAmn_IRC {
const DEBUG = 1;
const IRC_HOST = 'localhost';
const IRC_PORT = 8193;
const DAMN_HOST = 'chat.deviantart.com';
const DAMN_PORT = 3900;
@Two9A
Two9A / decronym.php
Last active Sep 22, 2021
Decronym: A simple Reddit bot
View decronym.php
<?php
/**
* Dirty, dirty Reddit bot: Decronym
*/
class Reddit {
const USERNAME = 'Decronym';
const PASSWORD = '***';
const CLIENTID = '***';
const SECRET = '***';
@Two9A
Two9A / starfield.html
Created Apr 19, 2015
The simplest star field you'll ever find
View starfield.html
<title>Starfield</title>
<script>
addEventListener('load', function() {
var stars = [];
var ctx = field.getContext('2d');
var gen = function(z) {
return {
x: 0 | (Math.random() * 800 - 400),
y: 0 | (Math.random() * 600 - 300),
z: z || (0 | Math.random() * 15)
@Two9A
Two9A / src-global.h
Created Jun 25, 2011
Qt compile issues...
View src-global.h
QT += network xml
QT -= gui
TARGET = QtCoreLib
TEMPLATE = lib
DEFINES += QTCORELIB_LIBRARY
INCLUDEPATH += src/logger \
src
@Two9A
Two9A / Tomcat log
Created Jun 16, 2011
CAS startup error
View Tomcat log
INFO: Undeploying context [/cas]
Jun 16, 2011 8:57:31 AM org.apache.catalina.startup.HostConfig deployWAR
INFO: Deploying web application archive cas.war
Jun 16, 2011 8:57:32 AM org.apache.catalina.startup.TldConfig tldScanJar
SEVERE: Exception processing TLD META-INF/c-1_0-rt.tld in JAR at resource path /opt/jasperserver-pro-3.5.1/apache-tomcat/webapps/cas/WEB-INF/lib/
standard-1.1.2.jar in context /cas
java.lang.NullPointerException
at org.apache.xerces.impl.dtd.models.DFAContentModel.buildDFA(DFAContentModel.java:538)
at org.apache.xerces.impl.dtd.models.DFAContentModel.<init>(DFAContentModel.java:253)
at org.apache.xerces.impl.dtd.DTDGrammar.createChildModel(DTDGrammar.java:2279)