Skip to content

Instantly share code, notes, and snippets.

@tjb0607
tjb0607 / vid2gif.sh
Created December 30, 2023 23:36
vid2gif.sh - uses ffmpeg and gifsicle to convert a video to a gif within a filesize constraint
#!/bin/bash
echo "Usage: vid2gif.sh <input> <output>"
echo -n "Enter desired delay (1/100 of seconds): "
read delay
fps=$(expr 100 / $delay)
read -p "Enter width [default: -1]: " width
width=${width:--1}
read -p "Enter height [default: -1]: " height
height=${height:--1}
read -p "Enter start timestamp [default: 0]: " tstart
@tjb0607
tjb0607 / ff57-tabs-mousewheel.js
Last active November 20, 2017 10:53 — forked from benoitryder/ff57-tabs-mousewheel.js
Change tabs with mousewheel in Firefox 57
// Change tabs with mousewheel
// Run into Browser Toolbox console
var onTabWheel = function(ev) {
if (ev.deltaMode == 1 /* DOM_DELTA_LINE */) {
var idx = gBrowser.tabContainer.getIndexOfItem(gBrowser.selectedTab);
if (ev.deltaY > 0) {
if (idx + 1 < gBrowser.tabs.length) {
gBrowser.selectTabAtIndex(idx + 1);
} else {
<head>
<meta charset="utf-8"/>
<title>
Update Notifier - NEOKOSMOS
</title>
<link href="favicon-32x32.png" rel="shortcut icon" id="favicon"/>
<meta name="viewport" content="width=540"/>
<meta name="description" content="The official update notifier for NEOKOSMOS"/>
<link href='https://fonts.googleapis.com/css?family=Press+Start+2P' rel='stylesheet' type='text/css'>
<link href='https://fonts.googleapis.com/css?family=Inconsolata' rel='stylesheet' type='text/css'>
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by ICU configure 57.1, which was
generated by GNU Autoconf 2.69. Invocation command line was
$ ./configure --prefix=/usr --sysconfdir=/etc --mandir=/usr/share/man
## --------- ##
## Platform. ##
<!DOCTYPE html>
<html>
<head>
<meta content="" name="image:Background Image">
<meta content="" name="image:Sidebar Image">
<meta content="http://media.tumblr.com/tumblr_m2um3ywXLE1qfamg6.gif" name=
"image:Cursor">
<meta content="http://media.tumblr.com/tumblr_m9ssoqN7Ix1roozkr.gif" name=
"image:Custom Favicon">
<meta content="" name="image:Left Corner Image">
@tjb0607
tjb0607 / i3-gaps-tumblr
Last active November 28, 2017 11:26
i3-gaps theme for tumblr
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8"/>
<title>{title}</title>
<link rel="shortcut icon" href="{Favicon}">
<link rel="stylesheet" type="text/css" href="http://static.tumblr.com/bwey4ra/4Hynod13t/i3-numix-tumblr.css">
<meta name="viewport" content="width=600px"/>
<script>
var cursorBlinker;
@tjb0607
tjb0607 / meme.c
Last active August 29, 2015 14:20
literally no documentation lmao
/*
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2004 Sam Hocevar <sam@hocevar.net>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
urxvt.background: [90]#1c1c1c
! COLORS
! Molokai Color Scheme
! By Jake Eaton
! Manpage colors
*colorIT: #87af5f
*colorBD: #d7d7d7
*colorUL: #87afd7
*foreground: #FFFFFF
@tjb0607
tjb0607 / meme.cpp
Created April 17, 2015 22:33
meme.cpp
/*****************************************************
* Name: Tyler Beatty
* Date Created: 2015-04-16
* Date Modified: 2015-04-17
* Lab Number: Programming Exercise 2
* Filename: PE 2 Tyler Beatty.cpp
*
* Input:
* A text file named "cosby.txt"
*
#/usr/bin/python3
import socket
import sys
import time
import re
import random
import linecache
import html
import threading
from datetime import datetime,date